mirror of
https://gitlab.com/RemixDev/deemix-gui-pyweb.git
synced 2024-12-29 10:56:06 +00:00
Added fix for #2
This commit is contained in:
parent
655e40bb6f
commit
96c8afe555
|
@ -6,6 +6,7 @@ from os import path
|
||||||
|
|
||||||
from flask import Flask, render_template, request, session
|
from flask import Flask, render_template, request, session
|
||||||
from flask_socketio import SocketIO, emit
|
from flask_socketio import SocketIO, emit
|
||||||
|
from werkzeug.middleware.proxy_fix import ProxyFix
|
||||||
|
|
||||||
import app
|
import app
|
||||||
from deemix.api.deezer import Deezer
|
from deemix.api.deezer import Deezer
|
||||||
|
@ -47,6 +48,7 @@ gui_dir = resource_path(path.join('webui', 'public'))
|
||||||
server = CustomFlask(__name__, static_folder=gui_dir, template_folder=gui_dir)
|
server = CustomFlask(__name__, static_folder=gui_dir, template_folder=gui_dir)
|
||||||
server.config['SEND_FILE_MAX_AGE_DEFAULT'] = 1 # disable caching
|
server.config['SEND_FILE_MAX_AGE_DEFAULT'] = 1 # disable caching
|
||||||
socketio = SocketIO(server, async_mode='threading')
|
socketio = SocketIO(server, async_mode='threading')
|
||||||
|
server.wsgi_app = ProxyFix(server.wsgi_app, x_for=1, x_proto=1)
|
||||||
|
|
||||||
class SocketInterface(MessageInterface):
|
class SocketInterface(MessageInterface):
|
||||||
def send(self, message, value=None):
|
def send(self, message, value=None):
|
||||||
|
|
Loading…
Reference in a new issue