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

[5.8] Prevent a job from firing if it's been marked as deleted #29204

Merged
merged 1 commit into from
Jul 18, 2019
Merged

[5.8] Prevent a job from firing if it's been marked as deleted #29204

merged 1 commit into from
Jul 18, 2019

Conversation

gms8994
Copy link
Contributor

@gms8994 gms8994 commented Jul 17, 2019

See #29152 for previous discussion.

During queue job processing an Events\JobProcessing event is fired, which makes it possible to $job->delete(), however, $job->fire() still happens even on the deleted job.

This adds a check to the processing of the job to prevent that, though still fires an Events\JobProcessed event.

Tests included.

@taylorotwell taylorotwell merged commit 9227682 into laravel:5.8 Jul 18, 2019
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