Replies: 1 comment
-
My question would be: are |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Dear laravel artisans,
I'm using the package
spatie/laravel-permission
for RBAC inside my application.A middleware is running performing a simple role check:
Beside of this middleware I'm using a simple method inside a blade template file like:
The
canBeImpersonated()
method from inside theUser
model is simple:This will cause 2 SQL queries (doubled):
Is there an elegant way to prevent this from happening?
Beta Was this translation helpful? Give feedback.
All reactions