Improve error handling and timestamp formatting
This commit is contained in:
parent
7bf5419ce3
commit
6c8cbfddec
3 changed files with 17 additions and 3 deletions
|
@ -3,4 +3,19 @@
|
|||
require 'ncc';
|
||||
import('net.nosial.socialbox');
|
||||
|
||||
\Socialbox\Socialbox::handleRpc();
|
||||
try
|
||||
{
|
||||
\Socialbox\Socialbox::handleRpc();
|
||||
}
|
||||
catch(Exception $e)
|
||||
{
|
||||
http_response_code(500);
|
||||
|
||||
if(\Socialbox\Classes\Configuration::getSecurityConfiguration()->isDisplayInternalExceptions())
|
||||
{
|
||||
print_r($e);
|
||||
return;
|
||||
}
|
||||
|
||||
print('An internal error occurred');
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue