alecpl
2011-02-16 207cc0b9b3cfdfb29e4f02e83014320fd12eeb68
plugins/password/password.php
@@ -128,7 +128,15 @@
            // try to save the password
            else if (!($res = $this->_save($curpwd, $newpwd))) {
                $rcmail->output->command('display_message', $this->gettext('successfullysaved'), 'confirmation');
                // Reset session password
                $_SESSION['password'] = $rcmail->encrypt($newpwd);
                // Log password change
                if ($rcmail->config->get('password_log')) {
                    write_log('password', sprintf('Password changed for user %s (ID: %d) from %s',
                        $rcmail->user->get_username(), $rcmail->user->ID, rcmail_remote_ip()));
                }
            }
            else {
                $rcmail->output->command('display_message', $res, 'error');
@@ -232,8 +240,8 @@
        $result = password_save($curpass, $passwd);
        if (is_array($result)) {
            $result  = $result['code'];
            $message = $result['message'];
            $result  = $result['code'];
        }
        switch ($result) {