]> git.rm.cloudns.org Git - xonotic/xonstat.git/commitdiff
If no frag matrix row is found, show zeros.
authorAnt Zucaro <azucaro@gmail.com>
Tue, 17 Oct 2017 23:32:52 +0000 (19:32 -0400)
committerAnt Zucaro <azucaro@gmail.com>
Tue, 17 Oct 2017 23:32:52 +0000 (19:32 -0400)
If a player has no frags, s/he won't have a frag matrix row, but will
still have a record in the player_game_stats table.

xonstat/templates/frag_matrix.mako

index 7c1c5ceebc49496d423264fd3db7f306d89d6db2..47663c2bbed6b9295e89aaf3ed1da072f22ff0eb 100644 (file)
       else:
         victim_index = "-1"
     %>
+
+    % if pgfm:
     <td>${pgfm.matrix.get(victim_index, 0)}</td>
+    % else:
+    <td>0</td>
+    % endif
     % endfor
   </tr>
   % endfor