Skip to content

Support back-shift using e.g. "bshift_1_days"#24

Open
danielmorlock wants to merge 1 commit intomaxsivanov:masterfrom
danielmorlock:master
Open

Support back-shift using e.g. "bshift_1_days"#24
danielmorlock wants to merge 1 commit intomaxsivanov:masterfrom
danielmorlock:master

Conversation

@danielmorlock
Copy link
Copy Markdown

@danielmorlock danielmorlock commented May 15, 2020

Further adds a systemd service script

Comment thread handlers.js
const time = moment(parseInt(match[2], 10));
time.subtract(count, unit);
//time.subtract(count, unit);
time.add(count, unit);
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi! Why direction was changed here?

Comment thread handlers.js
req.proxyShift = {};
}
req.proxyShift[idx] = {
back: (match.splice(1,1)[0] == "b"),
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do not like this match.splice approach, it's is much better to just change all match indexes rather then manipulate match array in place

Comment thread handlers.js
back: (match.splice(1,1)[0] == "b"),
count: parseInt(match[1], 10),
unit: match[2]
unit: match[2],
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Coma will brake node 6 compatibility

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants