feat: some improvements
This commit is contained in:
9
app.py
9
app.py
@@ -6,7 +6,7 @@ from flask import Flask, send_file, jsonify
|
||||
from flask_socketio import SocketIO
|
||||
from redis import Redis
|
||||
|
||||
logging.basicConfig(level=logging.DEBUG)
|
||||
logging.basicConfig(level=logging.INFO)
|
||||
LOG = logging.getLogger(__name__)
|
||||
DATA_URL_PREFIX = 'data:image/jpeg;base64,'
|
||||
# DEBUG = True
|
||||
@@ -46,7 +46,12 @@ class CameraListener:
|
||||
@app.route('/<string:path>')
|
||||
@app.route('/<path:path>') # does not seem to work
|
||||
def index(path):
|
||||
return send_file('client/dist/index.html')
|
||||
if path == 'reset.css':
|
||||
return send_file('client/dist/reset.css')
|
||||
elif path == 'favicon.ico':
|
||||
return send_file('client/dist/favicon.ico')
|
||||
else:
|
||||
return send_file('client/dist/index.html')
|
||||
|
||||
|
||||
@app.route('/api/sounds')
|
||||
|
||||
Reference in New Issue
Block a user