1
0
mirror of https://github.com/moparisthebest/wallabag synced 2024-11-30 04:42:19 -05:00

fix to display the login successful message with the translation

This commit is contained in:
Nicolas Lœuillet 2014-07-22 18:01:27 +02:00
parent 955fc67438
commit 9cf6bac1a5

View File

@ -877,6 +877,14 @@ class Poche
$longlastingsession = isset($_POST['longlastingsession']); $longlastingsession = isset($_POST['longlastingsession']);
$passwordTest = ($isauthenticated) ? $user['password'] : Tools::encodeString($password . $login); $passwordTest = ($isauthenticated) ? $user['password'] : Tools::encodeString($password . $login);
Session::login($user['username'], $user['password'], $login, $passwordTest, $longlastingsession, array('poche_user' => new User($user))); Session::login($user['username'], $user['password'], $login, $passwordTest, $longlastingsession, array('poche_user' => new User($user)));
# reload l10n
$language = $user['config']['language'];
@putenv('LC_ALL=' . $language);
setlocale(LC_ALL, $language);
bindtextdomain($language, LOCALE);
textdomain($language);
$this->messages->add('s', _('welcome to your wallabag')); $this->messages->add('s', _('welcome to your wallabag'));
Tools::logm('login successful'); Tools::logm('login successful');
Tools::redirect($referer); Tools::redirect($referer);