Skip to content
Permalink
c10840ad96
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Go to file
 
 
Cannot retrieve contributors at this time
28 lines (22 sloc) 496 Bytes
<?php
namespace App\Policies;
use App\Models\User;
use App\Models\Profile;
use Illuminate\Auth\Access\HandlesAuthorization;
class ProfilePolicy
{
use HandlesAuthorization;
/**
* Create a new policy instance.
*
* @return void
*/
public function edit(User $user, Profile $profile)
{
return $user->id === $profile->user_id;
}
public function update(User $user, Profile $profile)
{
return $user->id === $profile->user_id;
}
}