You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello.
I am really loving this package! I've been using this successfully for a while now. However, today I got a problem. I set up "admin" role with permission "manage-roles".
But $user->can('manage-roles') == false.
Moreover, $user->hasRole('admin') == true.
So I set up a little testing: $role = \App\Role::where('name', 'admin')->first();
Finds my role - cool. dump($role->permissions);
Through relations property I can see that "manage-roles" entry of Role model - cool again. dump($role->hasPermission('manage-roles'));
I get false. I can't understand why. Any ideas?
Thank you!
The text was updated successfully, but these errors were encountered:
Hello.
I am really loving this package! I've been using this successfully for a while now. However, today I got a problem. I set up "admin" role with permission "manage-roles".
But
$user->can('manage-roles') == false
.Moreover,
$user->hasRole('admin') == true
.So I set up a little testing:
$role = \App\Role::where('name', 'admin')->first();
Finds my role - cool.
dump($role->permissions);
Through relations property I can see that "manage-roles" entry of Role model - cool again.
dump($role->hasPermission('manage-roles'));
I get false. I can't understand why. Any ideas?
Thank you!
The text was updated successfully, but these errors were encountered: