mirror of
https://github.com/jquery/jquery-ui.git
synced 2026-04-20 03:02:41 -04:00
Datepicker - Fixed #4956 - undefined variable: lookAhead()
This commit is contained in:
7
ui/jquery.ui.datepicker.js
vendored
7
ui/jquery.ui.datepicker.js
vendored
@@ -1157,6 +1157,13 @@ $.extend(Datepicker.prototype, {
|
||||
_possibleChars: function (format) {
|
||||
var chars = '';
|
||||
var literal = false;
|
||||
// Check whether a format character is doubled
|
||||
var lookAhead = function(match) {
|
||||
var matches = (iFormat + 1 < format.length && format.charAt(iFormat + 1) == match);
|
||||
if (matches)
|
||||
iFormat++;
|
||||
return matches;
|
||||
};
|
||||
for (var iFormat = 0; iFormat < format.length; iFormat++)
|
||||
if (literal)
|
||||
if (format.charAt(iFormat) == "'" && !lookAhead("'"))
|
||||
|
||||
Reference in New Issue
Block a user