Skip to content

Conversation

@smmcbride
Copy link

node-resque defines the suppressDuplicateTaskError flag when scheduling a task at a time that it is already scheduled. This PR adds that flag to the configuration and passes it through when calling node-resqueue's enqueueIn or enqueueAt functions.

node-resque defines the `suppressDuplicateTaskError` flag when scheduling a task at a time that it is already scheduled. This PR adds that flag to the configuration and passes it through when calling node-resqueue's `enqueueIn` or `enqueueAt` functions.
@shiny
Copy link
Owner

shiny commented Oct 20, 2025

Appreciate the pull request! I’ll check it out later.

@shiny
Copy link
Owner

shiny commented Oct 20, 2025

Currently, when a task is already scheduled, it returns undefined, which is inconsistent with the Promise<boolean | boolean[]> return type.
Do you think it would be better to add undefined or null to the return type definition, or treat the suppressed duplicate case as a boolean false result instead?

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