Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings
This repository was archived by the owner on Feb 18, 2022. It is now read-only.

Commit f838efe

Browse files
datepicker crash when you type Invalid Date #231
Don`t update value if user enter invalid date.
1 parent 45880fb commit f838efe

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

‎src/js/angular-datepicker.js‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -376,7 +376,7 @@
376376
}
377377
, unregisterDataSetWatcher = $scope.$watch('dateSet', function dateSetWatcher(newValue) {
378378

379-
if (newValue) {
379+
if (newValue&&!isNaN(Date.parse(newValue))) {
380380

381381
date = new Date(newValue);
382382

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /