Permalink
Browse files

fix tab 500 error

  • Loading branch information...
1 parent ca8e279 commit 3d65fc373a635b258f6bbb1aec1c740b57434c30 @evildmp committed Jun 3, 2013
Showing with 5 additions and 2 deletions.
  1. +5 −2 contacts_and_people/views.py
@@ -180,8 +180,11 @@ def person(request, slug, active_tab=""):
# mark the active tab, if there is one
if active_tab:
- tabs_dict[active_tab]["active"] = True
-
+ try:
+ tabs_dict[active_tab]["active"] = True
+ except KeyError:
+ raise http.Http404
+
# add tabs to the list of tabs
tabs = []
tabs.append(tabs_dict["default"])

0 comments on commit 3d65fc3

Please sign in to comment.