]> git.xonotic.org Git - xonotic/xonstat.git/blobdiff - xonstat/__init__.py
Add initial support for JSON on map_index view.
[xonotic/xonstat.git] / xonstat / __init__.py
index 15662a01c1167ce86bd880e03d331c049dd576aa..d3a6d98a5ca8e1e07d1fe185658c06bbe583acd2 100755 (executable)
@@ -73,6 +73,10 @@ def main(global_config, **settings):
         renderer="server_info.mako")
 
     # MAP ROUTES
+    config.add_route("map_index_json", "/maps.json")
+    config.add_view(map_index_json, route_name="map_index_json",
+        renderer="json")
+
     config.add_route("map_index", "/maps")
     config.add_view(map_index, route_name="map_index",
         renderer="map_index.mako")