]> de.git.xonotic.org Git - xonotic/xonstat.git/commitdiff
Do not 500 on missing player_ids. 404 instead.
authorAnt Zucaro <azucaro@gmail.com>
Tue, 11 Feb 2014 01:08:00 +0000 (20:08 -0500)
committerAnt Zucaro <azucaro@gmail.com>
Tue, 11 Feb 2014 01:08:00 +0000 (20:08 -0500)
xonstat/views/player.py

index 19ec08165039cd55790f70f51dc757b8284ceb09..5e56b08dafd6baca972d978914a2310fe38699d5 100644 (file)
@@ -525,16 +525,9 @@ def player_info_data(request):
         cake_day       = is_cake_day(player.create_dt)
 
     except Exception as e:
-        player         = None
-        games_played   = None
-        overall_stats  = None
-        fav_maps       = None
-        elos           = None
-        ranks          = None
-        recent_games   = None
-        recent_weapons = []
-        cake_day       = False
-        ## do not raise exceptions here (only for debugging)
+        raise pyramid.httpexceptions.HTTPNotFound
+
+        ## do not raise application exceptions here (only for debugging)
         # raise e
 
     return {'player':player,