role, ['superuser', 'manager']); } /** * Determine whether the user can update allocations. */ public function update(User $user, Allocation $allocation): bool { return in_array($user->role, ['superuser', 'manager']); } /** * Determine whether the user can delete allocations. */ public function delete(User $user, Allocation $allocation): bool { return in_array($user->role, ['superuser', 'manager']); } }