diff roundup/cgi/client.py @ 8577:ed1465c5963e

bug: add missing variable and use in both places
author John Rouillard <rouilj@ieee.org>
date Sun, 19 Apr 2026 21:57:22 -0400
parents b1024bf0d9f7
children 5cba36e42b8f
line wrap: on
line diff
--- a/roundup/cgi/client.py	Sun Apr 19 21:50:18 2026 -0400
+++ b/roundup/cgi/client.py	Sun Apr 19 21:57:22 2026 -0400
@@ -1704,8 +1704,9 @@
         # once all header checks have passed if it needs to be opened.
         otks = self.db.getOTKManager()
 
+        method = self.env['REQUEST_METHOD']
         # Assume: never allow changes via GET
-        if self.env['REQUEST_METHOD'] not in ['POST', 'PUT', 'DELETE']:
+        if method not in ['POST', 'PUT', 'DELETE']:
             if (self.form.list is not None) and ("@csrf" in self.form):
                 self.expire_exposed_keys(method)
             # do return here. Keys have been obsoleted.

Roundup Issue Tracker: http://roundup-tracker.org/