diff --git a/app/Http/Controllers/Api/V1/Admin/ApiAdminTeamUsersController.php b/app/Http/Controllers/Api/V1/Admin/ApiAdminTeamUsersController.php index 1ba383b..a0c4296 100644 --- a/app/Http/Controllers/Api/V1/Admin/ApiAdminTeamUsersController.php +++ b/app/Http/Controllers/Api/V1/Admin/ApiAdminTeamUsersController.php @@ -89,12 +89,11 @@ public function store(): JsonResponse */ $teamId = $this->request->get('team_id'); $userId = $this->request->get('user_id'); - $model = TeamUser::where('team_id', $teamId) - ->where('user_id', $userId) - ->first(); + $model = TeamUser::where('team_id', $teamId) + ->where('user_id', $userId) + ->first(); - if(!$model) - { + if (!$model) { $model = new TeamUser(); foreach ($validationArray as $key => $validationRule) { @@ -107,7 +106,6 @@ public function store(): JsonResponse $model->save(); } - $this->message = ApiResponse::RESPONSE_SAVED->value; $this->data = $model;