diff --git a/cronexpr_parse.go b/cronexpr_parse.go index be6ef17..0cf4272 100644 --- a/cronexpr_parse.go +++ b/cronexpr_parse.go @@ -75,27 +75,27 @@ var ( "2090": 2090, "2091": 2091, "2092": 2092, "2093": 2093, "2094": 2094, "2095": 2095, "2096": 2096, "2097": 2097, "2098": 2098, "2099": 2099, } monthTokens = map[string]int{ - `1`: 1, `jan`: 1, `january`: 1, - `2`: 2, `feb`: 2, `february`: 2, - `3`: 3, `mar`: 3, `march`: 3, - `4`: 4, `apr`: 4, `april`: 4, - `5`: 5, `may`: 5, - `6`: 6, `jun`: 6, `june`: 6, - `7`: 7, `jul`: 7, `july`: 7, - `8`: 8, `aug`: 8, `august`: 8, - `9`: 9, `sep`: 9, `september`: 9, + `1`: 1, `01`: 1, `jan`: 1, `january`: 1, + `2`: 2, `02`: 2, `feb`: 2, `february`: 2, + `3`: 3, `03`: 3, `mar`: 3, `march`: 3, + `4`: 4, `04`: 4, `apr`: 4, `april`: 4, + `5`: 5, `05`: 5, `may`: 5, + `6`: 6, `06`: 6, `jun`: 6, `june`: 6, + `7`: 7, `07`: 7, `jul`: 7, `july`: 7, + `8`: 8, `08`: 8, `aug`: 8, `august`: 8, + `9`: 9, `09`: 9, `sep`: 9, `september`: 9, `10`: 10, `oct`: 10, `october`: 10, `11`: 11, `nov`: 11, `november`: 11, `12`: 12, `dec`: 12, `december`: 12, } dowTokens = map[string]int{ - `0`: 0, `sun`: 0, `sunday`: 0, - `1`: 1, `mon`: 1, `monday`: 1, - `2`: 2, `tue`: 2, `tuesday`: 2, - `3`: 3, `wed`: 3, `wednesday`: 3, - `4`: 4, `thu`: 4, `thursday`: 4, - `5`: 5, `fri`: 5, `friday`: 5, - `6`: 6, `sat`: 6, `saturday`: 6, + `0`: 0, `00`: 0, `sun`: 0, `sunday`: 0, + `1`: 1, `01`: 1, `mon`: 1, `monday`: 1, + `2`: 2, `02`: 2, `tue`: 2, `tuesday`: 2, + `3`: 3, `03`: 3, `wed`: 3, `wednesday`: 3, + `4`: 4, `04`: 4, `thu`: 4, `thursday`: 4, + `5`: 5, `05`: 5, `fri`: 5, `friday`: 5, + `6`: 6, `06`: 6, `sat`: 6, `saturday`: 6, `7`: 0, } )