comparison MoinMoin/action/recoverpass.py @ 4336:4f3d0b92d1c9

add i18n to the password checker result messages, add request param
author Thomas Waldmann <tw AT waldmann-edv DOT de>
date Thu, 25 Sep 2008 18:31:24 +0200
parents 6b3274cd86c6
children eda647742453 4238b0c90871
comparison
equal deleted inserted replaced
4132:99ed52b53e4e 4336:4f3d0b92d1c9
171 msg_type = 'error' 171 msg_type = 'error'
172 if newpass == newpass2: 172 if newpass == newpass2:
173 pw_checker = request.cfg.password_checker 173 pw_checker = request.cfg.password_checker
174 pw_error = None 174 pw_error = None
175 if pw_checker: 175 if pw_checker:
176 pw_error = pw_checker(name, newpass) 176 pw_error = pw_checker(request, name, newpass)
177 if pw_error: 177 if pw_error:
178 msg = _("Password not acceptable: %s") % pw_error 178 msg = _("Password not acceptable: %s") % pw_error
179 if not pw_error: 179 if not pw_error:
180 u = user.User(request, user.getUserId(request, name)) 180 u = user.User(request, user.getUserId(request, name))
181 if u and u.valid and u.apply_recovery_token(token, newpass): 181 if u and u.valid and u.apply_recovery_token(token, newpass):