Skip to content

Commit

Permalink
change check validation http status code
Browse files Browse the repository at this point in the history
  • Loading branch information
pooya darchaman committed Nov 2, 2019
1 parent 8e86302 commit 8a11f6c
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/Http/Controllers/MobilePassportAuthController.php
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,7 @@ public function credentialStore(Request $request)
$response->setMessage($this->getTrans(__FUNCTION__, 'validation_failed'));
$response->setStatus(false);
$response->setError(99);
$response->setStatusCode(400);
return SmartResponse::response($response);
}
}
Expand Down Expand Up @@ -204,6 +205,7 @@ public function store(Request $request)
$response->setMessage($this->getTrans(__FUNCTION__, 'validation_failed'));
$response->setStatus(false);
$response->setError(99);
$response->setStatusCode(400);
return SmartResponse::response($response);
}
}
Expand Down Expand Up @@ -343,6 +345,7 @@ public function registerByOtp(Request $request)
$response->setMessage($this->getTrans(__FUNCTION__, 'validation_failed'));
$response->setStatus(false);
$response->setError(99);
$response->setStatusCode(400);
return SmartResponse::response($response);
}
}
Expand Down Expand Up @@ -386,6 +389,7 @@ public function confirmOtp(Request $request)
$response->setMessage($this->getTrans(__FUNCTION__, 'validation_failed'));
$response->setStatus(false);
$response->setError(99);
$response->setStatusCode(400);
return SmartResponse::response($response);
}
}
Expand Down Expand Up @@ -500,6 +504,7 @@ public function registerByPassword(Request $request)
$response->setMessage($this->getTrans(__FUNCTION__, 'validation_failed'));
$response->setStatus(false);
$response->setError(99);
$response->setStatusCode(400);
return SmartResponse::response($response);
}
}
Expand Down

0 comments on commit 8a11f6c

Please sign in to comment.