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...
1 parent 1d651fc commit 7f6154f18cd57e93bc70ce986d09fde5c088304d @nielx committed Jul 6, 2010
Showing with 3 additions and 0 deletions.
  1. +3 −0 mastertickets/web_ui.py
View
3 mastertickets/web_ui.py
@@ -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)

0 comments on commit 7f6154f

Please sign in to comment.