From 33bde27f07a6edf2ede5b63e12405571aec64f33 Mon Sep 17 00:00:00 2001 From: Harri Siirak Date: Tue, 21 Oct 2014 21:58:57 +0300 Subject: [PATCH] Fix regression introduced in version 0.4.4. Fixes #28 --- lib/expression.js | 4 ---- package.json | 2 +- test/expression.js | 4 ---- 3 files changed, 1 insertion(+), 9 deletions(-) diff --git a/lib/expression.js b/lib/expression.js index 7c3d12f2..18257a35 100644 --- a/lib/expression.js +++ b/lib/expression.js @@ -165,10 +165,6 @@ CronExpression._parseField = function _parseField (field, value, constraints) { ); } - if (field == 'dayOfWeek') { - value = value % 7; - } - if (value > max) { stack.push(value); } diff --git a/package.json b/package.json index 2053aeca..bb5c3c9c 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "cron-parser", - "version": "0.4.4", + "version": "0.4.5", "description": "Node.js library for parsing crontab instructions", "main": "lib/parser.js", "directories": { diff --git a/test/expression.js b/test/expression.js index db8cc9bd..0cd60680 100644 --- a/test/expression.js +++ b/test/expression.js @@ -461,8 +461,6 @@ test('day of month and week are both set and dow is 6,0', function(t) { var next = interval.next(); - console.error(next); - t.ok(next, 'Found next scheduled interval'); t.equal(next.getDay(), 6, 'Day matches'); t.equal(next.getMonth(), 7, 'Month matches'); @@ -501,8 +499,6 @@ test('day of month and week are both set and dow is 6-7', function(t) { var next = interval.next(); - console.error(next); - t.ok(next, 'Found next scheduled interval'); t.equal(next.getDay(), 6, 'Day matches'); t.equal(next.getMonth(), 7, 'Month matches');