summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/private/user.php1
-rw-r--r--lib/private/user/session.php1
2 files changed, 1 insertions, 1 deletions
diff --git a/lib/private/user.php b/lib/private/user.php
index 86a01f96258..08ead712028 100644
--- a/lib/private/user.php
+++ b/lib/private/user.php
@@ -246,7 +246,6 @@ class OC_User {
OC_Hook::emit( "OC_User", "pre_login", array( "run" => &$run, "uid" => $uid ));
if($uid) {
- session_regenerate_id(true);
self::setUserId($uid);
self::setDisplayName($uid);
self::getUserSession()->setLoginName($uid);
diff --git a/lib/private/user/session.php b/lib/private/user/session.php
index 1740bad5abe..cd03b30205f 100644
--- a/lib/private/user/session.php
+++ b/lib/private/user/session.php
@@ -157,6 +157,7 @@ class Session implements Emitter, \OCP\IUserSession {
if($user !== false) {
if (!is_null($user)) {
if ($user->isEnabled()) {
+ session_regenerate_id(true);
$this->setUser($user);
$this->setLoginName($uid);
$this->manager->emit('\OC\User', 'postLogin', array($user, $password));