aboutsummaryrefslogtreecommitdiff
path: root/server
diff options
context:
space:
mode:
Diffstat (limited to 'server')
-rw-r--r--server/server.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/server/server.py b/server/server.py
index f1ddaa9..ca28d51 100644
--- a/server/server.py
+++ b/server/server.py
@@ -1,3 +1,5 @@
+import time
+
from datetime import datetime
from flask import abort, Flask, jsonify
from flask_cors import CORS
@@ -11,12 +13,15 @@ CORS(app)
@app.route('/zones/', methods=['GET'])
def zones():
""" Return a list of common timezones """
+ # time.sleep(5) # Simulate slow connection
return jsonify(common_timezones)
@app.route('/time-at/<path:zone>', methods=['GET'])
def time_at(zone):
""" Return current time at given timezone """
+ # time.sleep(5) # Simulate slow connection
+
if zone not in common_timezones:
abort(404)