From: Isaac Cambron Date: Mon, 19 Aug 2013 03:10:05 +0000 (+0300) Subject: use the second day of each month to find the month name X-Git-Tag: 2.2.0~24^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F1006%2Fhead;p=thirdparty%2Fmoment.git use the second day of each month to find the month name --- diff --git a/moment.js b/moment.js index fe9df98a1..33713d85e 100644 --- a/moment.js +++ b/moment.js @@ -405,7 +405,7 @@ for (i = 0; i < 12; i++) { // make the regex if we don't have it already if (!this._monthsParse[i]) { - mom = moment([2000, i]); + mom = moment([2000, i, 2]); regex = '^' + this.months(mom, '') + '|^' + this.monthsShort(mom, ''); this._monthsParse[i] = new RegExp(regex.replace('.', ''), 'i'); }