Skip to content

Commit 86f25a5

Browse files
author
Bohdan Korablov
committed
MAGETWO-85983: [Backport for 2.1.x] Admin login always takes >30 sec when using Redis on 2.2.1 #12385
1 parent e719669 commit 86f25a5

File tree

1 file changed

+2
-11
lines changed

1 file changed

+2
-11
lines changed

lib/internal/Magento/Framework/Session/SessionManager.php

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -503,18 +503,9 @@ public function regenerateId()
503503
if (headers_sent()) {
504504
return $this;
505505
}
506-
//@see http://php.net/manual/en/function.session-regenerate-id.php#53480 workaround
506+
507507
if ($this->isSessionExists()) {
508-
$oldSessionId = session_id();
509-
session_regenerate_id();
510-
$newSessionId = session_id();
511-
session_id($oldSessionId);
512-
session_destroy();
513-
514-
$oldSession = $_SESSION;
515-
session_id($newSessionId);
516-
session_start();
517-
$_SESSION = $oldSession;
508+
session_regenerate_id(true);
518509
} else {
519510
session_start();
520511
}

0 commit comments

Comments
 (0)