. */ namespace App\Policies; use App\Profile; use App\User; use Illuminate\Auth\Access\HandlesAuthorization; class ProfilePolicy { use HandlesAuthorization; /** * Create a new policy instance. * * @return void */ public function __construct() { } public function edit(User $user, Profile $profile) { return $user->is($profile->user); } }