diff --git a/Classes/Controller/AbstractApiController.php b/Classes/Controller/AbstractApiController.php index 97fe5217..07407c11 100644 --- a/Classes/Controller/AbstractApiController.php +++ b/Classes/Controller/AbstractApiController.php @@ -83,7 +83,7 @@ protected function errorAction() { $error = $this->findFirstError($this->arguments->getValidationResults()); - if ($error instanceof Error) { + if (!($error instanceof Error)) { $error = new Error('Unknown Error while dispatching the controller action.', 1400683671); } @@ -115,4 +115,4 @@ protected function findFirstError(\TYPO3\CMS\Extbase\Error\Result $validationRes return null; } -} \ No newline at end of file +}