andre 4 лет назад
Родитель
Сommit
26fd1d9fde
1 измененных файлов с 3 добавлено и 2 удалено
  1. 3 2
      checkconfigureproduct.tpl

+ 3 - 2
checkconfigureproduct.tpl

@@ -1,6 +1,7 @@
 <script>
     function checkMailAddress ( mailname, maildomain, pid) {
         var xhttp = new XMLHttpRequest();
+        var success = false;
         xhttp.onreadystatechange = function() {
             if (this.readyState == 4 && this.status == 200) {
                 if( this.responseText.trim() == 'yes') {
@@ -14,7 +15,7 @@
                     $("#hintNumeric").text('');
                     $("#hintSymbols").text('');
                     $("#hintUpperLower").text('');
-                    var success = true;
+                    success = true;
                 } else {
                     console.log(this.responseText);
                     $(customFields[4]).prop("disabled",true);
@@ -26,7 +27,7 @@
                     $("#hintNumeric").text('');
                     $("#hintSymbols").text('');
                     $("#hintUpperLower").text('');
-                    var success = false;
+                    success = false;
                 }
             }
         };