diff --git a/framework/core/.travis.yml b/framework/core/.travis.yml index 4a684b9be..b217e0233 100644 --- a/framework/core/.travis.yml +++ b/framework/core/.travis.yml @@ -6,9 +6,6 @@ php: - 7.2 - hhvm -services: - - mysql - matrix: allow_failures: - php: hhvm diff --git a/framework/core/src/Api/ExceptionHandler/IlluminateValidationExceptionHandler.php b/framework/core/src/Api/ExceptionHandler/IlluminateValidationExceptionHandler.php index 31bf030ca..afc496c1d 100644 --- a/framework/core/src/Api/ExceptionHandler/IlluminateValidationExceptionHandler.php +++ b/framework/core/src/Api/ExceptionHandler/IlluminateValidationExceptionHandler.php @@ -32,7 +32,7 @@ class IlluminateValidationExceptionHandler implements ExceptionHandlerInterface public function handle(Exception $e) { $status = 422; - + $errors = $this->formatErrors($e->errors()); return new ResponseBag($status, $errors); diff --git a/framework/core/tests/Flarum/Api/Handler/IlluminateValidationExceptionHandlerTest.php b/framework/core/tests/Flarum/Api/Handler/IlluminateValidationExceptionHandlerTest.php index 298cee7b2..fb2262624 100644 --- a/framework/core/tests/Flarum/Api/Handler/IlluminateValidationExceptionHandlerTest.php +++ b/framework/core/tests/Flarum/Api/Handler/IlluminateValidationExceptionHandlerTest.php @@ -13,9 +13,8 @@ namespace Tests\Flarum\Api\Handler; use Exception; use Flarum\Api\ExceptionHandler\IlluminateValidationExceptionHandler; -use Illuminate\Translation\{ - Translator, ArrayLoader -}; +use Illuminate\Translation\ArrayLoader; +use Illuminate\Translation\Translator; use Illuminate\Validation\ValidationException; use Illuminate\Validation\Factory; use Tests\Test\TestCase;