Catch all exceptions.
This commit is contained in:
parent
dc012fa8a6
commit
5d1fe28723
1 changed files with 2 additions and 1 deletions
|
@ -1,6 +1,7 @@
|
|||
<?php
|
||||
namespace Makai\Whois;
|
||||
|
||||
use Exception;
|
||||
use Memcached;
|
||||
use Index\Routing\Route;
|
||||
use Index\Routing\RouteHandler;
|
||||
|
@ -58,7 +59,7 @@ class WhoisRoutes extends RouteHandler {
|
|||
$result = unserialize($result);
|
||||
$source = 'cache';
|
||||
}
|
||||
} catch (\RuntimeException $ex) {
|
||||
} catch (Exception $ex) {
|
||||
return [
|
||||
'error' => true,
|
||||
'text' => $ex->getMessage(),
|
||||
|
|
Loading…
Reference in a new issue