8000 [12.x] Adds `EagerLoad` attribute and `initializeOnQueue` hook by timacdonald · Pull Request #55590 · laravel/framework · GitHub
[go: up one dir, main page]

Skip to content

[12.x] Adds EagerLoad attribute and initializeOnQueue hook #55590

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

Draft
wants to merge 19 commits into
base: 12.x
Choose a base branch
from
Draft
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Lint
  • Loading branch information
timacdonald committed Apr 30, 2025
commit 4596d26b18f625b33988ea5934591ca8ac0fd587
1 change: 0 additions & 1 deletion src/Illuminate/Queue/SerializesModels.php
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,6 @@ public function __unserialize(array $values)
}
}


if (in_array(Queueable::class, class_uses_recursive($this)) && method_exists($this, 'initializeOnQueue')) {
Copy link
Contributor

Choose a reason for hiding this comment

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

I feel like swapping the order would be more optimal, but probably not by much:

if (method_exists($this, 'initializeOnQueue') && in_array(Queueable::class, class_uses_recursive($this))) {

Probably would only be important if this was called a lot.

$this->initializeOnQueue();
}
Expand Down
0