Skip to content
This repository has been archived by the owner on Feb 18, 2022. It is now read-only.

Commit

Permalink
Merge pull request #270 from adrianhara/master
Browse files Browse the repository at this point in the history
Fixed: date parse error when opening calendar with "special" date format string
  • Loading branch information
45kb authored Jun 7, 2017
2 parents 5d7573e + e01ea89 commit 793972c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/js/angular-datepicker.js
Original file line number Diff line number Diff line change
Expand Up @@ -313,15 +313,15 @@

switch (true) {
case el.indexOf('d') !== -1: {
d = dateSplit[index];
d = dateSplit[index - (formatDate.length - dateSplit.length)];
break;
}
case el.indexOf('M') !== -1: {
m = dateSplit[index];
m = dateSplit[index - (formatDate.length - dateSplit.length)];
break;
}
case el.indexOf('y') !== -1: {
y = dateSplit[index];
y = dateSplit[index - (formatDate.length - dateSplit.length)];
break;
}
default: {
Expand Down

0 comments on commit 793972c

Please sign in to comment.