cron-parser
Advanced tools
Comparing version 0.4.2 to 0.4.3
@@ -30,6 +30,10 @@ 'use strict'; | ||
Date.prototype.addDay = function addDay () { | ||
this.setDate(this.getDate() + 1); | ||
var day = this.getDate(); | ||
this.setDate(day + 1); | ||
this.setHours(0); | ||
this.setMinutes(0); | ||
this.setSeconds(0); | ||
if (this.getDate() === day) { | ||
this.setDate(day + 1); | ||
} | ||
}; | ||
@@ -36,0 +40,0 @@ |
{ | ||
"name": "cron-parser", | ||
"version": "0.4.2", | ||
"version": "0.4.3", | ||
"description": "Node.js library for parsing crontab instructions", | ||
@@ -28,3 +28,4 @@ "main": "lib/parser.js", | ||
"Alex Kit <alex.kit@atmajs.com>", | ||
"Santiago Gimeno <santiago.gimeno@gmail.com>" | ||
"Santiago Gimeno <santiago.gimeno@gmail.com>", | ||
"Daniel <darc.tec@gmail.com>" | ||
], | ||
@@ -31,0 +32,0 @@ "license": "MIT", |
@@ -404,1 +404,17 @@ var util = require('util'); | ||
}); | ||
test('Summertime bug test', function(t) { | ||
var month = new Date().getMonth() + 1; | ||
CronExpression.parse('0 0 0 1 '+month+' *', function(err, interval) { | ||
t.ifError(err, 'Interval parse error'); | ||
t.ok(interval, 'Interval parsed'); | ||
var next = interval.next(); | ||
// Before fix the bug it was getting a timeout error if you are | ||
// in a timezone that changes the DST to ST in the hour 00:00h. | ||
t.ok(next, 'Found next scheduled interval'); | ||
t.end(); | ||
}); | ||
}); |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
48813
21
1023