id == $bookmark->user_id; } /** * Determine whether the user can create bookmarks. * * @param \App\Models\User $user * @return mixed */ public function create(User $user) { return true; } /** * Determine whether the user can update the bookmark. * * @param \App\Models\User $user * @param \App\Models\Bookmark $bookmark * @return mixed */ public function update(User $user, Bookmark $bookmark) { return $user->id == $bookmark->user_id; } /** * Determine whether the user can delete the bookmark. * * @param \App\Models\User $user * @param \App\Models\Bookmark $bookmark * @return mixed */ public function delete(User $user, Bookmark $bookmark) { return $user->id == $bookmark->user_id; } /** * Determine whether the user can restore the bookmark. * * @param \App\Models\User $user * @param \App\Models\Bookmark $bookmark * @return mixed */ public function restore(User $user, Bookmark $bookmark) { return false; } /** * Determine whether the user can permanently delete the bookmark. * * @param \App\Models\User $user * @param \App\Models\Bookmark $bookmark * @return mixed */ public function forceDelete(User $user, Bookmark $bookmark) { return false; } }