Skip to content

Commit

Permalink
cs
Browse files Browse the repository at this point in the history
  • Loading branch information
specialtactics committed Sep 9, 2020
1 parent 06d8aaa commit 5a51774
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Exception/Handler.php
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@ protected function genericResponse(Throwable $exception)

$response = $this->newResponseArray();

array_walk_recursive($response, function (&$value, $key) use ($exception, $replacements) {
array_walk_recursive($response, function (&$value, $key) use ($replacements) {
if (Str::startsWith($value, ':') && isset($replacements[$value])) {
$value = $replacements[$value];
}
Expand All @@ -207,7 +207,7 @@ protected function getStatusCode(Throwable $exception)

if ($exception instanceof ValidationException) {
$statusCode = $exception->status;
} else if ($exception instanceof HttpExceptionInterface) {
} elseif ($exception instanceof HttpExceptionInterface) {
$statusCode = $exception->getStatusCode();
} else {
// By default throw 500
Expand Down

0 comments on commit 5a51774

Please sign in to comment.