returns error message on exception

This commit is contained in:
Adphi 2020-02-02 17:54:29 +01:00
부모 411e9e800f
커밋 4fecde9d9d
1개의 변경된 파일2개의 추가작업 그리고 9개의 파일을 삭제

파일 보기

@ -58,9 +58,8 @@ class OccController extends Controller
$this->application->run($input, $this->output);
return $this->output->fetch();
} catch (Exception $ex) {
exceptionHandler($ex);
} catch (Error $ex) {
exceptionHandler($ex);
$this->logger->logException($ex);
return "error: " . $ex->getMessage();
}
}
@ -87,9 +86,3 @@ class OccController extends Controller
}
}
function exceptionHandler($exception)
{
echo "An unhandled exception has been thrown:" . PHP_EOL;
echo $exception;
exit(1);
}