Skip to content

Commit b31475e

Browse files
authored
Update WebmanResponseTrait.php
1 parent a725338 commit b31475e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Traits/WebmanResponseTrait.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,6 +132,6 @@ public function renderableHandle(\Webman\Http\Request $request, \Throwable $e)
132132
return $this->fail('404 Url Not Found.', Response::HTTP_NOT_FOUND);
133133
}
134134

135-
return $this->fail($e->getMessage(), Response::HTTP_INTERNAL_SERVER_ERROR);
135+
return $this->fail($e->getMessage(), $e->getCode() ?: Response::HTTP_INTERNAL_SERVER_ERROR);
136136
}
137137
}

0 commit comments

Comments
 (0)