From daaf99adac5cefe7fd1e0cc8e303fcf6fb90f17b Mon Sep 17 00:00:00 2001 From: bwarsaw <> Date: Thu, 2 Jan 2003 05:31:55 +0000 Subject: main(): In the change-of-address section, we only want to show the "you are already using that email address" message if the newaddress matches the case-preserved (subscribed) address. Also, in the set_address section, if cpuser is None, set it to the the user address, since that's what we'll use now as the old address in the ChangeMemberAddress() call. This and related changes should fix problems when the address we're changing to differs for the current address by case only. --- Mailman/Cgi/options.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'Mailman') diff --git a/Mailman/Cgi/options.py b/Mailman/Cgi/options.py index da4562f7..ef080a68 100644 --- a/Mailman/Cgi/options.py +++ b/Mailman/Cgi/options.py @@ -1,4 +1,4 @@ -# Copyright (C) 1998,1999,2000,2001,2002 by the Free Software Foundation, Inc. +# Copyright (C) 1998-2003 by the Free Software Foundation, Inc. # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License @@ -284,7 +284,7 @@ def main(): _('Addresses did not match!')) print doc.Format() return - if newaddr == user: + if newaddr == cpuser: options_page(mlist, doc, user, cpuser, userlang, _('You are already using that email address')) print doc.Format() @@ -324,12 +324,14 @@ address. Upon confirmation, any other mailing list containing the address signal.signal(signal.SIGTERM, sigterm_handler) if set_address: + if cpuser is None: + cpuser = user # Register the pending change after the list is locked msg += _('A confirmation message has been sent to %(newaddr)s. ') mlist.Lock() try: try: - mlist.ChangeMemberAddress(user, newaddr, globally) + mlist.ChangeMemberAddress(cpuser, newaddr, globally) mlist.Save() finally: mlist.Unlock() -- cgit v1.2.3