|
61 | 61 | replace: function(new_array){ |
62 | 62 | if (!new_array) |
63 | 63 | return; |
64 | | - if (!$.isArray(new_array)) |
| 64 | + if (!Array.isArray(new_array)) |
65 | 65 | new_array = [new_array]; |
66 | 66 | this.clear(); |
67 | 67 | this.push.apply(this, new_array); |
|
176 | 176 | }, |
177 | 177 |
|
178 | 178 | _resolveDaysOfWeek: function(daysOfWeek){ |
179 | | - if (!$.isArray(daysOfWeek)) |
| 179 | + if (!Array.isArray(daysOfWeek)) |
180 | 180 | daysOfWeek = daysOfWeek.split(/[,\s]*/); |
181 | 181 | return $.map(daysOfWeek, Number); |
182 | 182 | }, |
|
263 | 263 | o.daysOfWeekHighlighted = this._resolveDaysOfWeek(o.daysOfWeekHighlighted||[]); |
264 | 264 |
|
265 | 265 | o.datesDisabled = o.datesDisabled||[]; |
266 | | - if (!$.isArray(o.datesDisabled)) { |
| 266 | + if (!Array.isArray(o.datesDisabled)) { |
267 | 267 | o.datesDisabled = o.datesDisabled.split(','); |
268 | 268 | } |
269 | 269 | o.datesDisabled = $.map(o.datesDisabled, function(d){ |
|
579 | 579 | }, |
580 | 580 |
|
581 | 581 | setDates: function(){ |
582 | | - var args = $.isArray(arguments[0]) ? arguments[0] : arguments; |
| 582 | + var args = Array.isArray(arguments[0]) ? arguments[0] : arguments; |
583 | 583 | this.update.apply(this, args); |
584 | 584 | this._trigger('changeDate'); |
585 | 585 | this.setValue(); |
586 | 586 | return this; |
587 | 587 | }, |
588 | 588 |
|
589 | 589 | setUTCDates: function(){ |
590 | | - var args = $.isArray(arguments[0]) ? arguments[0] : arguments; |
| 590 | + var args = Array.isArray(arguments[0]) ? arguments[0] : arguments; |
591 | 591 | this.setDates.apply(this, $.map(args, this._utc_to_local)); |
592 | 592 | return this; |
593 | 593 | }, |
|
1039 | 1039 |
|
1040 | 1040 | //Check if uniqueSort exists (supported by jquery >=1.12 and >=2.2) |
1041 | 1041 | //Fallback to unique function for older jquery versions |
1042 | | - if ($.isFunction($.uniqueSort)) { |
| 1042 | + if (typeof $.uniqueSort === "function") { |
1043 | 1043 | clsName = $.uniqueSort(clsName); |
1044 | 1044 | } else { |
1045 | 1045 | clsName = $.unique(clsName); |
|
0 commit comments