|
@@ -38,8 +38,11 @@ def steps():
|
|
|
|
|
|
@app.route("/events", methods=["GET"])
|
|
@app.route("/events", methods=["GET"])
|
|
def events():
|
|
def events():
|
|
- boudicca_events = requests.get("https://api.boudicca.events/event").json()
|
|
|
|
- return render_template('events.html', events=boudicca_events)
|
|
|
|
|
|
+ boudicca_req = requests.get("https://api.boudicca.events/event")
|
|
|
|
+ events = []
|
|
|
|
+ if boudicca_req.status_code == 200:
|
|
|
|
+ events = boudicca_req.json()
|
|
|
|
+ return render_template('events.html', events=events)
|
|
|
|
|
|
|
|
|
|
@app.route("/mitgestaltung", methods=["GET"])
|
|
@app.route("/mitgestaltung", methods=["GET"])
|