]> git.ipfire.org Git - thirdparty/moment.git/commitdiff
use the second day of each month to find the month name 1006/head
authorIsaac Cambron <icambron@gmail.com>
Mon, 19 Aug 2013 03:10:05 +0000 (06:10 +0300)
committerIsaac Cambron <icambron@gmail.com>
Mon, 19 Aug 2013 03:10:05 +0000 (06:10 +0300)
moment.js

index fe9df98a1b1c122176ae123ec6834069b21cd57f..33713d85e5d6f96e6b7c9281b0cda1be3b077dc0 100644 (file)
--- a/moment.js
+++ b/moment.js
             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');
                 }