Browse Source

Improved Zendesk invalid URL check.

Thorsten Eckel 7 years ago
parent
commit
bd8ba66721
1 changed files with 2 additions and 2 deletions
  1. 2 2
      app/controllers/import_zendesk_controller.rb

+ 2 - 2
app/controllers/import_zendesk_controller.rb

@@ -40,8 +40,8 @@ class ImportZendeskController < ApplicationController
       return
     end
 
-    # since 2016-10-15 a redirect to a signup page has been implemented
-    if response.body =~ /(Take it for a risk-free|Take it for a risk-free)/i
+    # since 2016-10-15 a redirect to a marketing page has been implemented
+    if response.body !~ /#{params[:url]}/
       render json: {
         result: 'invalid',
         message_human: 'Hostname not found!',