Improve error handling and timestamp formatting
This commit is contained in:
parent
7bf5419ce3
commit
6c8cbfddec
3 changed files with 17 additions and 3 deletions
|
@ -30,7 +30,7 @@ class CaptchaManager
|
|||
}
|
||||
|
||||
$answer = Utilities::randomString(6, 'ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789');
|
||||
$current_time = (new DateTime())->setTimestamp(time());
|
||||
$current_time = (new DateTime())->setTimestamp(time())->format('Y-m-d H:i:s');
|
||||
|
||||
if(!self::captchaExists($peer_uuid))
|
||||
{
|
||||
|
|
|
@ -30,7 +30,6 @@
|
|||
{
|
||||
Logger::getLogger()->error('Failed to parse the client request', $e);
|
||||
http_response_code($e->getCode());
|
||||
print($e->getMessage());
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue