Skip to content

Commit

Permalink
Merge pull request #1953 from Eonasdan/master
Browse files Browse the repository at this point in the history
fix
  • Loading branch information
Eonasdan committed Dec 31, 2016
2 parents 6384819 + dad92a9 commit 6050b7e
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 5 deletions.
3 changes: 2 additions & 1 deletion Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,8 @@ module.exports = function (grunt) {
grunt.task.run([
'bump_version:' + version,
'build:travis',
'docs'
'docs',
'nugetpack'
]);
});
};
2 changes: 1 addition & 1 deletion build/js/bootstrap-datetimepicker.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
"require": {
"robloach/component-installer": "*",
"components/jquery": ">=1.9.1",
"moment": ">=2.10.5"
"moment/moment": ">=2.10.5"
},
"extra": {
"component": {
Expand Down
2 changes: 1 addition & 1 deletion docs/Options.md
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,7 @@ Takes a `boolean`. If set to `false` the picker will display similar to `sideByS
### locale

Default: moment.locale()
Accepts: string, moment.local('locale')
Accepts: string, moment.locale('locale')

See [momentjs](https://github.com/moment/moment/tree/develop/locale) for valid locales.

Expand Down
3 changes: 2 additions & 1 deletion src/js/bootstrap-datetimepicker.js
Original file line number Diff line number Diff line change
Expand Up @@ -947,6 +947,7 @@

input.blur();

currentViewMode = 0;
viewDate = date.clone();

return picker;
Expand All @@ -958,7 +959,7 @@

parseInputDate = function (inputDate) {
if (options.parseInputDate === undefined) {
if (!moment.isMoment(inputDate)) {
if (!moment.isMoment(inputDate) || inputDate instanceof Date) {
inputDate = getMoment(inputDate);
}
} else {
Expand Down

0 comments on commit 6050b7e

Please sign in to comment.