adaptive-expressions
Advanced tools
Comparing version 4.11.0-dev.20200901.8b7db50 to 4.11.0-dev.20200902.4a95911
@@ -72,2 +72,5 @@ "use strict"; | ||
} | ||
if (validHour >= 24) { | ||
validHour -= 24; | ||
} | ||
validMinute = parsed.minute; | ||
@@ -74,0 +77,0 @@ validSecond = parsed.second; |
@@ -65,3 +65,3 @@ "use strict"; | ||
const dayOfMonth = convertedDateTime.date(); | ||
if (parsed.month <= month || (parsed.month === month && parsed.dayOfMonth < dayOfMonth)) { | ||
if (parsed.month < month || (parsed.month === month && parsed.dayOfMonth < dayOfMonth)) { | ||
validYear = year; | ||
@@ -68,0 +68,0 @@ } |
@@ -72,2 +72,5 @@ "use strict"; | ||
} | ||
if (validHour < 0) { | ||
validHour += 24; | ||
} | ||
validMinute = parsed.minute; | ||
@@ -74,0 +77,0 @@ validSecond = parsed.second; |
@@ -23,2 +23,5 @@ "use strict"; | ||
return functionUtils_1.FunctionUtils.apply((args) => { | ||
if (typeof args[0] === 'string') { | ||
return args[0]; | ||
} | ||
return JSON.stringify(args[0]) | ||
@@ -25,0 +28,0 @@ .replace(/(^\'*)/g, '') |
@@ -272,6 +272,6 @@ "use strict"; | ||
"\u0102\x03\x02\x02\x02\u0103\u0104\x03\x02\x02\x02\u0104Q\x03\x02\x02" + | ||
"\x02\u0105\u0106\n\v\x02\x02\u0106S\x03\x02\x02\x02\x19\x02\x03\\bdfh" + | ||
"\x87\xB3\xB9\xBB\xC7\xCC\xCE\xD2\xDC\xDE\xE6\xE8\xEC\xFB\xFD\u0103\b\x03" + | ||
"\x05\x02\x07\x03\x02\b\x02\x02\x03&\x03\t\x03\x02\x06\x02\x02"; | ||
"\x02\u0105\u0106\v\x02\x02\x02\u0106S\x03\x02\x02\x02\x19\x02\x03\\bd" + | ||
"fh\x87\xB3\xB9\xBB\xC7\xCC\xCE\xD2\xDC\xDE\xE6\xE8\xEC\xFB\xFD\u0103\b" + | ||
"\x03\x05\x02\x07\x03\x02\b\x02\x02\x03&\x03\t\x03\x02\x06\x02\x02"; | ||
exports.ExpressionAntlrLexer = ExpressionAntlrLexer; | ||
//# sourceMappingURL=ExpressionAntlrLexer.js.map |
@@ -5,3 +5,3 @@ { | ||
"description": "Common Expression Language", | ||
"version": "4.11.0-dev.20200901.8b7db50", | ||
"version": "4.11.0-dev.20200902.4a95911", | ||
"license": "MIT", | ||
@@ -53,3 +53,3 @@ "keywords": [ | ||
"clean": "erase /q /s .\\lib", | ||
"set-version": "npm version --allow-same-version 4.11.0-dev.20200901.8b7db50", | ||
"set-version": "npm version --allow-same-version 4.11.0-dev.20200902.4a95911", | ||
"test": "tsc && tsc ./tests/expressionProperty.test.ts && mocha tests/ --timeout 60000", | ||
@@ -56,0 +56,0 @@ "antlr-build-expression": "antlr4ts src/parser/ExpressionAntlrLexer.g4 -o src/parser/generated && antlr4ts src/parser/ExpressionAntlrParser.g4 -visitor -o src/parser/generated", |
@@ -42,3 +42,3 @@ /** | ||
if (!formatRegex.test(args[0] as string)) { | ||
error = `${args[0]} must be a timex string which only contains minutes and seconds, for example: 'TXX:15:28'` | ||
error = `${args[0]} must be a timex string which only contains minutes and seconds, for example: 'TXX:15:28'`; | ||
} | ||
@@ -77,2 +77,6 @@ } | ||
if (validHour >= 24) { | ||
validHour -= 24; | ||
} | ||
validMinute = parsed.minute; | ||
@@ -79,0 +83,0 @@ validSecond = parsed.second; |
@@ -70,3 +70,3 @@ /** | ||
if (parsed.month <= month || (parsed.month === month && parsed.dayOfMonth < dayOfMonth)) { | ||
if (parsed.month < month || (parsed.month === month && parsed.dayOfMonth < dayOfMonth)) { | ||
validYear = year; | ||
@@ -73,0 +73,0 @@ } else { |
@@ -42,3 +42,3 @@ /** | ||
if (!formatRegex.test(args[0] as string)) { | ||
error = `${args[0]} must be a timex string which only contains minutes and seconds, for example: 'TXX:15:28'` | ||
error = `${args[0]} must be a timex string which only contains minutes and seconds, for example: 'TXX:15:28'`; | ||
} | ||
@@ -77,2 +77,6 @@ } | ||
if (validHour < 0) { | ||
validHour += 24; | ||
} | ||
validMinute = parsed.minute; | ||
@@ -79,0 +83,0 @@ validSecond = parsed.second; |
@@ -24,2 +24,6 @@ /** | ||
return FunctionUtils.apply((args: any[]): string => { | ||
if (typeof args[0] === 'string') { | ||
return args[0]; | ||
} | ||
return JSON.stringify(args[0]) | ||
@@ -26,0 +30,0 @@ .replace(/(^\'*)/g, '') |
@@ -292,5 +292,5 @@ // Generated from src/parser/ExpressionAntlrLexer.g4 by ANTLR 4.7.3-SNAPSHOT | ||
"\u0102\x03\x02\x02\x02\u0103\u0104\x03\x02\x02\x02\u0104Q\x03\x02\x02" + | ||
"\x02\u0105\u0106\n\v\x02\x02\u0106S\x03\x02\x02\x02\x19\x02\x03\\bdfh" + | ||
"\x87\xB3\xB9\xBB\xC7\xCC\xCE\xD2\xDC\xDE\xE6\xE8\xEC\xFB\xFD\u0103\b\x03" + | ||
"\x05\x02\x07\x03\x02\b\x02\x02\x03&\x03\t\x03\x02\x06\x02\x02"; | ||
"\x02\u0105\u0106\v\x02\x02\x02\u0106S\x03\x02\x02\x02\x19\x02\x03\\bd" + | ||
"fh\x87\xB3\xB9\xBB\xC7\xCC\xCE\xD2\xDC\xDE\xE6\xE8\xEC\xFB\xFD\u0103\b" + | ||
"\x03\x05\x02\x07\x03\x02\b\x02\x02\x03&\x03\t\x03\x02\x06\x02\x02"; | ||
public static __ATN: ATN; | ||
@@ -297,0 +297,0 @@ public static get _ATN(): ATN { |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
2162595
39208