aboutsummaryrefslogtreecommitdiffstats
path: root/ui/jquery.ui.datepicker.js
diff options
context:
space:
mode:
authorJörn Zaefferer <joern.zaefferer@gmail.com>2011-06-28 16:41:36 -0500
committerJörn Zaefferer <joern.zaefferer@gmail.com>2011-06-28 16:41:36 -0500
commit96de2aa04a4e323199ac942b086958d7227f879a (patch)
tree91a42d2b84c117d218636bd8e4045bf937f7e7c2 /ui/jquery.ui.datepicker.js
parenteffdd5d19c534f8445ebafe4212278c4366b0041 (diff)
parent76e2b98a312cfab3d754aac5068ad965e544840c (diff)
downloadjquery-ui-96de2aa04a4e323199ac942b086958d7227f879a.tar.gz
jquery-ui-96de2aa04a4e323199ac942b086958d7227f879a.zip
Merge remote branch 'pgraham/master'
Diffstat (limited to 'ui/jquery.ui.datepicker.js')
-rw-r--r--ui/jquery.ui.datepicker.js5
1 files changed, 4 insertions, 1 deletions
diff --git a/ui/jquery.ui.datepicker.js b/ui/jquery.ui.datepicker.js
index dda8585fd..aeadde4ee 100644
--- a/ui/jquery.ui.datepicker.js
+++ b/ui/jquery.ui.datepicker.js
@@ -1102,7 +1102,10 @@ $.extend(Datepicker.prototype, {
}
}
if (iValue < value.length){
- throw "Extra/unparsed characters found in date: " + value.substring(iValue);
+ var extra = value.substr(iValue);
+ if (!/^\s+/.test(extra)) {
+ throw "Extra/unparsed characters found in date: " + extra;
+ }
}
if (year == -1)
year = new Date().getFullYear();