-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
[V5] Cache loader improvements #1912
Conversation
78ecd2f
to
f224b25
Compare
To me, the old and new code is unreadable. Could you split this up in dedicated functions that are clearly named and explain what is happening? |
f532174
to
e566d2a
Compare
Will these cache improvements break if people have already cached things using the old way? |
@freekmurze no breaks, there is a // must be removed on next mayor version
if (! isset($this->permissions['permissions'])) {
$this->forgetCachedPermissions();
$this->loadPermissions();
return;
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Typo
@freekmurze will this PR be merged? |
Thanks! 👍 |
collect($this->permissions)->map()
and later->each()
)array_map
instead ofcollect($this->permissions)->map()->all()
and othercollect()
again with the first collect