when querying event, replace one by first to avoid raising an exception when the event is not found
--- a/annot-server/webapp/views.py Thu Oct 23 10:42:11 2014 +0200
+++ b/annot-server/webapp/views.py Thu Oct 23 17:51:55 2014 +0200
@@ -32,7 +32,7 @@
def page_annotationclient_event_code(event_code):
#TODO: check event code + get event session
event_query = db_session.query(models.Event).filter(models.Event.code == event_code, models.Event.active == True)
- event = event_query.one()
+ event = event_query.first()
if not event:
abort(404)