mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2025-01-19 02:56:15 +00:00
minor optimisation, refs comments on 81875cfeb1
This commit is contained in:
parent
1eccec02e4
commit
a266a9493d
1 changed files with 2 additions and 3 deletions
|
@ -714,11 +714,10 @@ class CakeSession {
|
|||
* @return void
|
||||
*/
|
||||
public static function renew() {
|
||||
$id = session_id();
|
||||
if (!$id) {
|
||||
if (!session_id()) {
|
||||
return;
|
||||
}
|
||||
if ($id || isset($_COOKIE[session_name()])) {
|
||||
if (isset($_COOKIE[session_name()])) {
|
||||
setcookie(Configure::read('Session.cookie'), '', time() - 42000, self::$path);
|
||||
}
|
||||
session_regenerate_id(true);
|
||||
|
|
Loading…
Add table
Reference in a new issue