diff options
| author | bwarsaw | 1999-03-05 19:53:02 +0000 |
|---|---|---|
| committer | bwarsaw | 1999-03-05 19:53:02 +0000 |
| commit | 46ba3b2acf3243f031548091e344201b0278be08 (patch) | |
| tree | 7cbcd5289d56d1ade1911525001d52c79d1b5e69 | |
| parent | 97d8f58144ccae5b22b8eaeeabd1450d318a404b (diff) | |
| download | mailman-46ba3b2acf3243f031548091e344201b0278be08.tar.gz mailman-46ba3b2acf3243f031548091e344201b0278be08.tar.zst mailman-46ba3b2acf3243f031548091e344201b0278be08.zip | |
main(): Scott had a comment asking whether the check for membership
should use FindMatchingAddresses(). I think it should, so I've made
that change.
Also, farther down, just changed some inconsistent indentation.
| -rw-r--r-- | Mailman/Cgi/handle_opts.py | 21 |
1 files changed, 9 insertions, 12 deletions
diff --git a/Mailman/Cgi/handle_opts.py b/Mailman/Cgi/handle_opts.py index 4cad556e2..da133ca22 100644 --- a/Mailman/Cgi/handle_opts.py +++ b/Mailman/Cgi/handle_opts.py @@ -89,11 +89,8 @@ def main(): error = 0 operation = "" user = Utils.LCDomain(user) - # - # XXX shouldn't this check use Utils.FindMatchingAddresses? - # -scott - if not list.members.has_key(user) \ - and not list.digest_members.has_key(user): + if not Utils.FindMatchingAddresses(user, list.members, + list.digest_members): PrintResults("%s not a member!<p>" % user) if form.has_key("unsub"): @@ -124,13 +121,13 @@ def main(): elif form.has_key("emailpw"): - try: - list.MailUserPassword(user) - PrintResults("A reminder of your password " - "has been emailed to you.<p>") - except Errors.MMBadUserError: - PrintResults("Your password entry has not been found. The" - " list administrator is being notified.<p>") + try: + list.MailUserPassword(user) + PrintResults("A reminder of your password " + "has been emailed to you.<p>") + except Errors.MMBadUserError: + PrintResults("Your password entry has not been found. The" + " list administrator is being notified.<p>") elif form.has_key("othersubs"): |
