/** * Remove the specified resource from storage. * * @param int $id * @return Response */ public function destroy($id) { if ($this->group_check->destroy($id)) { return BaseController::httpNotFound(); } else { $this->group_gestion->delete($id); return BaseController::httpOk(); } }
/** * Remove the specified resource from storage. * * @param int $id * @return Response */ public function destroy() { if ($this->delete_validation->fails()) { return BaseController::httpError($this->delete_validation); } elseif (!$this->friend_check->exist()) { return BaseController::httpNotFound(); } else { $this->friend_gestion->destroy(); return BaseController::httpOk(); } }
/** * Remove the specified resource from storage. * * @param int $id * @return Response */ public function destroy($id) { if ($this->comment_check->missing($id)) { return BaseController::httpNotFound(); } else { $this->comment_gestion->destroy($id); return BaseController::httpOk(); } }
public function friendsFeed($id) { if ($this->list_validation->fails()) { return BaseController::httpError($this->list_validation); } else { if ($this->post_check->missingUser($id)) { return BaseController::httpNotFound(); } else { return BaseController::httpContent($this->post_gestion->friendsFeed($id), 'friends_posts'); } } }
/** * Remove the specified resource from storage. * * @param int $id * @return Response */ public function destroy() { if ($this->vote_check->badVote()) { return BaseController::httpNotFound(); } else { $this->vote_gestion->destroy(); return BaseController::httpOk(); } }
public function avatar($id) { /*if($this->avatar_validation->fails()) { return BaseController::httpError($this->avatar_validation); }else*/ if ($this->user_check->missing($id)) { return BaseController::httpNotFound(); } else { $this->user_gestion->avatar($id); return BaseController::httpOk(); } }