diff options
author | ianb <devnull@localhost> | 2005-11-17 03:23:40 +0000 |
---|---|---|
committer | ianb <devnull@localhost> | 2005-11-17 03:23:40 +0000 |
commit | efe0885cfab0ae0d78144f44482c0c2fc18a7a8d (patch) | |
tree | 876c33e8a1331771150ab9c5808db916eadea779 /paste/evalexception | |
parent | 03b1fb013bf7c58747842530944543a0fe427820 (diff) | |
download | paste-efe0885cfab0ae0d78144f44482c0c2fc18a7a8d.tar.gz |
Unfortunately, can't get POST variables reliably
Diffstat (limited to 'paste/evalexception')
-rw-r--r-- | paste/evalexception/middleware.py | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/paste/evalexception/middleware.py b/paste/evalexception/middleware.py index e4b5794..69b5c44 100644 --- a/paste/evalexception/middleware.py +++ b/paste/evalexception/middleware.py @@ -248,7 +248,7 @@ class EvalException(object): head_html += self.eval_javascript(base_path, count) repost_button = make_repost_button(environ) page = error_template % { - 'repost_button': repost_button, + 'repost_button': repost_button or '', 'head_html': head_html, 'body': html} return [page] @@ -389,9 +389,14 @@ def make_repost_button(environ): if environ['REQUEST_METHOD'] == 'GET': return ('<button onclick="window.location.href=%r">' 'Re-GET Page</button><br>' % url) + else: + # @@: I'd like to reconstruct this, but I can't because + # the POST body is probably lost at this point, and + # I can't get it back :( + return None fields = [] for name, value_list in wsgilib.parse_formvars( - environ, all_as_list=True, include_get_vars=False): + environ, all_as_list=True, include_get_vars=False).items(): for value in value_list: if hasattr(value, 'filename'): # @@: Arg, we'll just submit the body, and leave out |