diff options
author | ArthurHoaro <arthur@hoa.ro> | 2020-10-28 14:02:08 +0100 |
---|---|---|
committer | ArthurHoaro <arthur@hoa.ro> | 2020-10-28 14:02:08 +0100 |
commit | d3f6d525253eb7bb041d9436cbf213c10524a85c (patch) | |
tree | 014c3658074c29a97b0d5a990d379adbaab8d754 /application/security | |
parent | 156061d445fd23d033a52f84954484a3349c988a (diff) | |
download | Shaarli-d3f6d525253eb7bb041d9436cbf213c10524a85c.tar.gz Shaarli-d3f6d525253eb7bb041d9436cbf213c10524a85c.tar.zst Shaarli-d3f6d525253eb7bb041d9436cbf213c10524a85c.zip |
Fix compatiliby issue on login with PHP 7.1
session_set_cookie_params does not return any value in PHP 7.1
Diffstat (limited to 'application/security')
-rw-r--r-- | application/security/SessionManager.php | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/application/security/SessionManager.php b/application/security/SessionManager.php index 36df8c1c..96bf193c 100644 --- a/application/security/SessionManager.php +++ b/application/security/SessionManager.php | |||
@@ -293,9 +293,12 @@ class SessionManager | |||
293 | return session_start(); | 293 | return session_start(); |
294 | } | 294 | } |
295 | 295 | ||
296 | public function cookieParameters(int $lifeTime, string $path, string $domain): bool | 296 | /** |
297 | * Be careful, return type of session_set_cookie_params() changed between PHP 7.1 and 7.2. | ||
298 | */ | ||
299 | public function cookieParameters(int $lifeTime, string $path, string $domain): void | ||
297 | { | 300 | { |
298 | return session_set_cookie_params($lifeTime, $path, $domain); | 301 | session_set_cookie_params($lifeTime, $path, $domain); |
299 | } | 302 | } |
300 | 303 | ||
301 | public function regenerateId(bool $deleteOldSession = false): bool | 304 | public function regenerateId(bool $deleteOldSession = false): bool |