Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Apply #4878: [PATCH] "'NoneType' object is unsubscriptable" error

Fixes the error message when a non-existing ticket is passed to the post_process_request hook
  • Loading branch information...
commit 7f6154f18cd57e93bc70ce986d09fde5c088304d 1 parent 1d651fc
Niels Sascha Reedijk authored
Showing with 3 additions and 0 deletions.
  1. +3 −0  mastertickets/web_ui.py
3  mastertickets/web_ui.py
View
@@ -41,6 +41,9 @@ def pre_process_request(self, req, handler):
def post_process_request(self, req, template, data, content_type):
if req.path_info.startswith('/ticket/'):
+ # In case of an invalid ticket, the data is invalid
+ if not data:
+ return template, data, content_type
tkt = data['ticket']
links = TicketLinks(self.env, tkt)
Please sign in to comment.
Something went wrong with that request. Please try again.