{"action":"opened","issue":{"url":"https://api.github.com/repos/angular-ui/bootstrap/issues/3937","labels_url":"https://api.github.com/repos/angular-ui/bootstrap/issues/3937/labels{/name}","comments_url":"https://api.github.com/repos/angular-ui/bootstrap/issues/3937/comments","events_url":"https://api.github.com/repos/angular-ui/bootstrap/issues/3937/events","html_url":"https://github.com/angular-ui/bootstrap/issues/3937","id":94655201,"number":3937,"title":"datetimepicker - wrong validatio","user":{"login":"agrudz","id":13309807,"avatar_url":"https://avatars.githubusercontent.com/u/13309807?v=3","gravatar_id":"","url":"https://api.github.com/users/agrudz","html_url":"https://github.com/agrudz","followers_url":"https://api.github.com/users/agrudz/followers","following_url":"https://api.github.com/users/agrudz/following{/other_user}","gists_url":"https://api.github.com/users/agrudz/gists{/gist_id}","starred_url":"https://api.github.com/users/agrudz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/agrudz/subscriptions","organizations_url":"https://api.github.com/users/agrudz/orgs","repos_url":"https://api.github.com/users/agrudz/repos","events_url":"https://api.github.com/users/agrudz/events{/privacy}","received_events_url":"https://api.github.com/users/agrudz/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-07-13T07:13:21Z","updated_at":"2015-07-13T07:13:21Z","closed_at":null,"body":"I use datepicker and i'm trying to type date using keyboard. The specified format for datetimepicker is yyyy-MM-dd. When i type whole data it works correct. when i tries to change for examle month it starts to fail.\r\nThe path to the bug looks like this:\r\n1. I have correct date in my datetimepicker for example 2015-07-14\r\n2. I whant to change it to 2015-08-14 so i start editing it and im removing 7 - i have 2015-0-14 writen in my datetimepicker. The validation shows me that it is not correct date ant this is fine for me\r\n3.I type 8 and i have 2015-08-14 in my datetimepicker. The validation message still shows up...\r\nThere is a screen from my debuger - \r\n![debuger](https://cloud.githubusercontent.com/assets/13309807/8644345/9de19cfe-293e-11e5-9686-801f46bf8860.png)\r\nYou can notice that houres, minutes and seconds have NaN values. The bug is easy to correct.\r\nI edited this piece of code\r\ni replace this :\r\n     if ( isValid(fields.year, fields.month, fields.date) ) {\r\n        dt = new Date(fields.year, fields.month, fields.date, fields.hours, fields.minutes, fields.seconds,\r\n          fields.milliseconds || 0);\r\n      }\r\n with:\r\n\r\n       dt = new Date(fields.year, fields.month, fields.date, fields.hours || 0, fields.minutes || 0, fields.seconds || 0,\r\n          fields.milliseconds || 0);\r\n"}}