Skip to content
This repository was archived by the owner on Feb 14, 2019. It is now read-only.

Commit 2b5d425

Browse files
set null rather new Date instance
1 parent 15019f3 commit 2b5d425

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

js/bootstrap-datetimepicker.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1452,7 +1452,7 @@
14521452
},
14531453
parseDate: function (date, format, language, type) {
14541454
if (!(/^(\d+-?|\d+\/?|.)+\d.*/).test(date)) {
1455-
date = new Date;
1455+
return null;
14561456
}
14571457
if (date instanceof Date) {
14581458
var dateUTC = new Date(date.valueOf() - date.getTimezoneOffset() * 60000);

0 commit comments

Comments
 (0)