aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Mailman/OldStyleMemberships.py20
1 files changed, 10 insertions, 10 deletions
diff --git a/Mailman/OldStyleMemberships.py b/Mailman/OldStyleMemberships.py
index cc42cb90..8ade3565 100644
--- a/Mailman/OldStyleMemberships.py
+++ b/Mailman/OldStyleMemberships.py
@@ -1,17 +1,17 @@
-# Copyright (C) 2001,2002 by the Free Software Foundation, Inc.
+# Copyright (C) 2001-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
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
-#
+#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
-#
+#
# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software
+# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
"""Old style Mailman membership adaptor.
@@ -211,7 +211,7 @@ class OldStyleMemberships(MemberAdaptor.MemberAdaptor):
# Set the member's default set of options
if self.__mlist.new_member_options:
self.__mlist.user_options[member] = self.__mlist.new_member_options
-
+
def removeMember(self, member):
assert self.__mlist.Locked()
self.__assertIsMember(member)
@@ -240,15 +240,15 @@ class OldStyleMemberships(MemberAdaptor.MemberAdaptor):
password = self.__mlist.passwords.get(memberkey,
Utils.MakeRandomPassword())
lang = self.getMemberLanguage(memberkey)
- # Add the new member
+ # First, possibly delete the old member
+ if not nodelete:
+ self.removeMember(memberkey)
+ # Now, add the new member
self.addNewMember(newaddress, realname=fullname, digest=digestsp,
password=password, language=lang)
# Set the entire options bitfield
if flags:
- self.__mlist.user_options[memberkey] = flags
- # Delete the old memberkey
- if not nodelete:
- self.removeMember(memberkey)
+ self.__mlist.user_options[newaddress.lower()] = flags
def setMemberPassword(self, memberkey, password):
assert self.__mlist.Locked()