Browse Source

Fixed regexp

Brendan Abolivier 8 years ago
parent
commit
14d1683bfb
Signed by: Brendan Abolivier <contact@brendanabolivier.com> GPG key ID: 8EF1500759F70623
1 changed files with 2 additions and 2 deletions
  1. 2
    2
      front/form.js

+ 2
- 2
front/form.js View File

19
         if(script.src) {
19
         if(script.src) {
20
             let url = script.src;
20
             let url = script.src;
21
             // This should be our script
21
             // This should be our script
22
-            if(url.match(/:[0-9]+\/form\.js$/)) {
22
+            if(url.match(/form\.js$/)) {
23
                 // Port has been found
23
                 // Port has been found
24
-                return url.match(/^(http:\/\/[^\/]+)/)[1];
24
+                return url.match(/^(https?:\/\/[^\/]+)/)[1];
25
             }
25
             }
26
         }
26
         }
27
     }    
27
     }