Skip to content

Commit ab2cb90

Browse files
fnagelscottgonzalez
authored andcommitted
Datepicker: Properly define default for dateFormat option
1 parent 9c66d2e commit ab2cb90

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

ui/datepicker.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ var idIncrement = 0,
3939
$.widget( "ui.datepicker", {
4040
options: {
4141
appendTo: null,
42-
dateFormat: null,
42+
dateFormat: { date: "short" },
4343
// TODO review
4444
eachDay: $.noop,
4545
numberOfMonths: 1,
@@ -59,7 +59,6 @@ $.widget( "ui.datepicker", {
5959
},
6060

6161
_create: function() {
62-
this.options.dateFormat = this.options.dateFormat || { date: "short" };
6362
this.date = $.date( null, this.options.dateFormat );
6463

6564
this.date.eachDay = this.options.eachDay;

0 commit comments

Comments
 (0)