Fixed issue with PDO exception not returning correct type for error-code.

This commit is contained in:
Simon Sessingo
2018-02-27 08:20:25 +01:00
parent 6d7d07669b
commit 79c82c90cc
2 changed files with 7 additions and 7 deletions
@@ -36,7 +36,7 @@ class CookieTokenProvider implements ITokenProvider
try {
return bin2hex(random_bytes(32));
} catch(\Exception $e) {
throw new SecurityException($e->getMessage(), $e->getCode(), $e->getPrevious());
throw new SecurityException($e->getMessage(), (int)$e->getCode(), $e->getPrevious());
}
}