projects
/
roojs1
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2f25d54
)
Date.js
author
Alan
<alan@roojs.com>
Wed, 15 Dec 2021 08:45:36 +0000
(16:45 +0800)
committer
Alan
<alan@roojs.com>
Wed, 15 Dec 2021 08:45:36 +0000
(16:45 +0800)
Date.js
patch
|
blob
|
history
diff --git
a/Date.js
b/Date.js
index
6f217a5
..
687a8ae
100644
(file)
--- a/
Date.js
+++ b/
Date.js
@@
-371,7
+371,7
@@
Date.formatCodeToRegex = function(character, currentGroup) {
s:"(\\d{1,2})"}; // Numeric representation of a month, without leading zeros
case "m":
return {g:1,
- c:"m =
parseInt(results[" + currentGroup + "], 10) - 1
;\n",
+ c:"m =
Math.max(0,parseInt(results[" + currentGroup + "], 10) - 1)
;\n",
s:"(\\d{2})"}; // Numeric representation of a month, with leading zeros
case "t":
return {g:0,