user should set into session before postLogin hook otherwise it will break not only the files_encryption app

This commit is contained in:
Florin Peter 2013-05-31 21:30:13 +02:00
parent d85a10ebc5
commit b840de4e01

View file

@ -116,8 +116,8 @@ class Session implements Emitter {
if ($user) {
$result = $user->checkPassword($password);
if ($result and $user->isEnabled()) {
$this->manager->emit('\OC\User', 'postLogin', array($user, $password));
$this->setUser($user);
$this->manager->emit('\OC\User', 'postLogin', array($user, $password));
return true;
} else {
return false;