Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[11.x] Add withoutDelay() to the Queueable trait #51555

Merged
merged 2 commits into from
May 24, 2024

Conversation

KennedyTedesco
Copy link
Contributor

Some of my jobs have a default delay, but on some specific occasions, I need to dispatch them without delay. So, I find myself doing this a lot:

dispatch((new MyJob($data))->delay(0));

So, I thought about having a shortcut for this:

dispatch((new MyJob($data))->withoutDelay());

I mean, this is just for UX. I'm fine with doing delay(0), but I prefer withoutDelay(). =)

@taylorotwell taylorotwell merged commit f6f5a95 into laravel:11.x May 24, 2024
28 checks passed
@KennedyTedesco KennedyTedesco deleted the queue branch May 24, 2024 14:24
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