Пробел\Permission\Exceptions\PermissionDoesNotExistPhp

Кемеровские программисты php общаются здесь
Гость
Пробел\Permission\Exceptions\PermissionDoesNotExist

Сообщение Гость »


I was trying to use spatie role and permission but when i try to update role and permission it gives me the above error and highlights the if statement in the function below located inside the user model
public static function roleHasPermissions($role,$permissions){

Код: Выделить всё

    $hasPermission=true;

// dd($role);

// dd($perm);

foreach($permissions as $permission){

if(!$role->hasPermissionTo($permission)){

$hasPermission=true;

}

}

return $hasPermission;

}
To update role and permission


Источник: https://stackoverflow.com/questions/781 ... esnotexist

Вернуться в «Php»