summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbwarsaw2001-07-03 04:38:06 +0000
committerbwarsaw2001-07-03 04:38:06 +0000
commit8f7f10fcfa97a5101df95a6bf888e2b56a0547a8 (patch)
tree8f7e055dd973961ff35712fc68cb0581374f7057
parentb0f7342b6f59f12f41773759b24db3df398c8917 (diff)
downloadmailman-8f7f10fcfa97a5101df95a6bf888e2b56a0547a8.tar.gz
mailman-8f7f10fcfa97a5101df95a6bf888e2b56a0547a8.tar.zst
mailman-8f7f10fcfa97a5101df95a6bf888e2b56a0547a8.zip
main(), show_results(): Removed unnecessary global declarations.
main(): If the WebAuthenticate() fails, search for the form key `adminpw' -- not `admlogin' -- to decide whether to include the error message or not. The former is the cgi key for the password field, while the latter is the key for the submit button, which isn't included in a Mozilla posted form if the Enter key is hit instead of clicking on the button.
-rw-r--r--Mailman/Cgi/admin.py6
1 files changed, 1 insertions, 5 deletions
diff --git a/Mailman/Cgi/admin.py b/Mailman/Cgi/admin.py
index ca2d0f08f..fdbee9a3d 100644
--- a/Mailman/Cgi/admin.py
+++ b/Mailman/Cgi/admin.py
@@ -63,8 +63,6 @@ NL = '\n'
def main():
- global CATEGORIES
-
# Try to find out which list is being administered
parts = Utils.GetPathPieces()
if not parts:
@@ -89,7 +87,7 @@ def main():
if not mlist.WebAuthenticate((mm_cfg.AuthListAdmin,
mm_cfg.AuthSiteAdmin),
cgidata.getvalue('adminpw', '')):
- if cgidata.has_key('admlogin'):
+ if cgidata.has_key('adminpw'):
# This is a re-authorization attempt
msg = Bold(FontSize('+1', _('Authorization failed.'))).Format()
else:
@@ -356,8 +354,6 @@ def option_help(mlist, varhelp):
def show_results(mlist, doc, category, category_suffix, cgidata):
# Produce the results page
- global CATEGORIES
-
adminurl = mlist.GetScriptURL('admin')
for k, v in CATEGORIES: