add some permession

This commit is contained in:
2023-11-29 23:56:04 +05:00
parent f073020e86
commit c3ef45134c
8 changed files with 123 additions and 23 deletions

View File

@@ -96,6 +96,10 @@ class UserPolicy
*/
public function forceDelete(User $user, User $model): bool
{
if ($model->email === 'nurmuhammet@mail.com') {
return false;
}
if ($user->isAdmin()) {
return true;
}