Skip to content
Permalink
Browse files

datepicker: fixed two global variables

  • Loading branch information
jzaefferer committed Sep 15, 2009
1 parent 219c81a commit e6efe11ac4bcebd3d8eb8d1ce688a468e3dfcd30
Showing with 3 additions and 2 deletions.
  1. +3 −2 ui/ui.datepicker.js
@@ -872,7 +872,7 @@ $.extend(Datepicker.prototype, {
if (altField) { // update alternate field too
var altFormat = this._get(inst, 'altFormat') || this._get(inst, 'dateFormat');
var date = this._getDate(inst);
dateStr = this.formatDate(altFormat, date, this._getFormatConfig(inst));
var dateStr = this.formatDate(altFormat, date, this._getFormatConfig(inst));
$(altField).each(function() { $(this).val(dateStr); });
}
},
@@ -1192,7 +1192,8 @@ $.extend(Datepicker.prototype, {
_setDateFromField: function(inst) {
var dateFormat = this._get(inst, 'dateFormat');
var dates = inst.input ? inst.input.val() : null;
var date = defaultDate = this._getDefaultDate(inst);
var date, defaultDate;
date = defaultDate = this._getDefaultDate(inst);
var settings = this._getFormatConfig(inst);
try {
date = this.parseDate(dateFormat, dates, settings) || defaultDate;

0 comments on commit e6efe11

Please sign in to comment.
You can’t perform that action at this time.