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
Using the Gate helper
All permissions are automatically defined inside Laravel's Gate helper.
Gate::allows('create.posts'); @can('create.posts');
$user->can('create.posts');
I cannot get this to work.
So, while this return TRUE:
$user->hasPermissionTo('users.write');
This return FALSE:
\Gate::allows('users.write');
The text was updated successfully, but these errors were encountered:
From your site:
Using the Gate helper
All permissions are automatically defined inside Laravel's Gate helper.
Gate::allows('create.posts');
@can('create.posts');
$user->can('create.posts');
I cannot get this to work.
So, while this return TRUE:
$user->hasPermissionTo('users.write');
This return FALSE:
\Gate::allows('users.write');
The text was updated successfully, but these errors were encountered: