From 5e967b6d379da385055bc43d36187bc89c87e8e3 Mon Sep 17 00:00:00 2001 From: KennethLavrsen Date: Sat, 6 Jun 2009 17:49:10 +0000 Subject: [PATCH] Item1690: Call to the resetpasswd script is not logged Improved fix. We want the logging to happen when the password has been reset and not let the logging be depending on successful emailing. We actually want to be able to debug when someone says they reset the password but never got the email. Thanks to Olivier for the hint git-svn-id: http://svn.foswiki.org/branches/Release01x00@4049 0b4bb1d4-4e5a-0410-9cc4-b2b747904278 --- core/lib/Foswiki/UI/Register.pm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/core/lib/Foswiki/UI/Register.pm b/core/lib/Foswiki/UI/Register.pm index 662608b54c..29a99b6d2b 100755 --- a/core/lib/Foswiki/UI/Register.pm +++ b/core/lib/Foswiki/UI/Register.pm @@ -504,8 +504,6 @@ sub resetPassword { $good = $good && _resetUsersPassword( $session, $userName, $introduction, \$message ); - - $session->logEvent('resetpasswd', $userName) if $good; } my $action = ''; @@ -567,6 +565,9 @@ sub _resetUsersPassword { return 0; } + # Now that we have successfully reset the password we log the event + $session->logEvent('resetpasswd', $login); + # absolute URL context for email generation $session->enterContext('absolute_urls');