Browse Source

static is a reserved keyword

static is a reserved keyword (http://www.w3schools.com/js/js_reserved.asp) which may cause issues for some parsing tools
kheyse-autodesk 9 years ago
parent
commit
8accb4b1ff
1 changed files with 5 additions and 5 deletions
  1. 5 5
      js/inputmask.js

+ 5 - 5
js/inputmask.js

@@ -2630,11 +2630,11 @@
 
 
 		function renderColorMask(input, buffer, caretPos) {
 		function renderColorMask(input, buffer, caretPos) {
 			function handleStatic() {
 			function handleStatic() {
-				if (!static && (test.fn === null || testPos.input === undefined)) {
-					static = true;
+				if (!isStatic && (test.fn === null || testPos.input === undefined)) {
+					isStatic = true;
 					maskTemplate += "<span class='im-static''>"
 					maskTemplate += "<span class='im-static''>"
-				} else if (static && (test.fn !== null && testPos.input !== undefined)) {
-					static = false;
+				} else if (isStatic && (test.fn !== null && testPos.input !== undefined)) {
+					isStatic = false;
 					maskTemplate += "</span>"
 					maskTemplate += "</span>"
 				}
 				}
 			}
 			}
@@ -2647,7 +2647,7 @@
 					caretPos = {begin: caretPos, end: caretPos};
 					caretPos = {begin: caretPos, end: caretPos};
 				}
 				}
 
 
-				var maskTemplate = "", static = false;
+				var maskTemplate = "", isStatic = false;
 				if (buffer != "") {
 				if (buffer != "") {
 					var ndxIntlzr, pos = 0,
 					var ndxIntlzr, pos = 0,
 						test, testPos, lvp = getLastValidPosition();
 						test, testPos, lvp = getLastValidPosition();