mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-10-16 09:22:33 +00:00
Try to catch bad operations.
This commit is contained in:
@@ -26,6 +26,8 @@
|
||||
* @author Taylor Otwell <taylor@laravel.com>
|
||||
*/
|
||||
|
||||
use Symfony\Component\HttpFoundation\Exception\SuspiciousOperationException;
|
||||
|
||||
define('LARAVEL_START', microtime(true));
|
||||
|
||||
/*
|
||||
@@ -72,9 +74,14 @@ $app = require_once __DIR__ . '/../bootstrap/app.php';
|
||||
|
||||
$kernel = $app->make(Illuminate\Contracts\Http\Kernel::class);
|
||||
|
||||
$response = $kernel->handle(
|
||||
$request = Illuminate\Http\Request::capture()
|
||||
);
|
||||
try {
|
||||
$response = $kernel->handle(
|
||||
$request = Illuminate\Http\Request::capture()
|
||||
);
|
||||
} catch(SuspiciousOperationException $e) {
|
||||
die('Cannot handle this situation.');
|
||||
|
||||
}
|
||||
$response->send();
|
||||
|
||||
$kernel->terminate($request, $response);
|
||||
|
Reference in New Issue
Block a user