From ff5a40fad185ad2c0f7e7904ea88974fe4c4df24 Mon Sep 17 00:00:00 2001 From: mailman Date: Wed, 20 May 1998 16:57:22 +0000 Subject: New replacement for new .FormatDisabledNotice(). Use a null path when PATH_INFO is not present - list_info will thereby be null, and the proper error page will be produced. --- cgi/options | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/cgi/options b/cgi/options index ecbcd497b..5baaf233b 100755 --- a/cgi/options +++ b/cgi/options @@ -6,7 +6,7 @@ Takes listname/userid in PATH_INFO, expecting an "obscured" userid. (Depending on the mm_utils.{O,Uno}bscureEmail utilities tolerance, will work fine with an unobscured ids as well.)""" -__version__ = "$Revision: 405 $" +__version__ = "$Revision: 526 $" # We don't need to lock in this script, because we're never going to change # data. @@ -25,7 +25,10 @@ except IOError: doc = htmlformat.HeadlessDocument() -path = os.environ['PATH_INFO'] +try: + path = os.environ['PATH_INFO'] +except KeyError: + path = "" list_info = mm_utils.GetPathPieces(path) if len(list_info) < 2: @@ -65,7 +68,6 @@ if list.obscure_addresses: else: presentable_user = user - replacements = list.GetStandardReplacements() replacements[''] = list.FormatOptionButton( mm_cfg.Digests, 1, user) @@ -79,6 +81,7 @@ replacements[''] = list.FormatOptionButton( mm_cfg.DisableDelivery, 0, user) replacements[''] = list.FormatOptionButton( mm_cfg.DisableDelivery, 1, user) +replacements[''] = list.FormatDisabledNotice(user) replacements[''] = list.FormatOptionButton( mm_cfg.AcknowlegePosts, 0, user) replacements[''] = list.FormatOptionButton( -- cgit v1.2.3-70-g09d2