Expand view.

This commit is contained in:
James Cole
2024-08-03 18:27:19 +02:00
parent 762d898fee
commit 3811aff206
7 changed files with 40 additions and 10 deletions

View File

@@ -30,13 +30,10 @@ use Illuminate\Support\Facades\Log;
class AccountPolicy
{
/**
* TODO needs better authentication.
* TODO needs better authentication, also for group.
*/
public function view(User $user, Account $account): bool
{
die('OK1');
return true;
return auth()->check() && $user->id === $account->user_id;
}