diff --git a/app/Exceptions/Handler.php b/app/Exceptions/Handler.php index bea49f80..e0b0e827 100644 --- a/app/Exceptions/Handler.php +++ b/app/Exceptions/Handler.php @@ -1,7 +1,9 @@ is('api*')) { - if ($e instanceof \CachetHQ\Cachet\Repositories\InvalidModelValidationException) { + if ($e instanceof InvalidModelValidationException) { return Response::make(['status_code' => 400, 'message' => 'Bad Request'], 400); } - if ($e instanceof \Illuminate\Database\Eloquent\ModelNotFoundException) { + if ($e instanceof ModelNotFoundException) { return Response::make(['status_code' => 404, 'error' => 'Resource not found'], 404); } }