forked from platypush/platypush
Removed remaining references to websocket port.
This commit is contained in:
parent
bdbbd24e6f
commit
c0a948f8ce
3 changed files with 7 additions and 14 deletions
|
@ -1,7 +1,7 @@
|
|||
from flask import Blueprint, render_template
|
||||
|
||||
from platypush.backend.http.app import template_folder
|
||||
from platypush.backend.http.app.utils import authenticate, get_websocket_port
|
||||
from platypush.backend.http.app.utils import authenticate
|
||||
from platypush.backend.http.utils import HttpUtils
|
||||
|
||||
dashboard = Blueprint('dashboard', __name__, template_folder=template_folder)
|
||||
|
@ -17,9 +17,10 @@ __routes__ = [
|
|||
@authenticate()
|
||||
def render_dashboard(name):
|
||||
"""Route for the dashboard"""
|
||||
return render_template('index.html',
|
||||
return render_template(
|
||||
'index.html',
|
||||
utils=HttpUtils,
|
||||
websocket_port=get_websocket_port())
|
||||
)
|
||||
|
||||
|
||||
# vim:sw=4:ts=4:et:
|
||||
|
|
|
@ -78,14 +78,6 @@ def get_http_port():
|
|||
return http_conf.get('port', HttpBackend._DEFAULT_HTTP_PORT)
|
||||
|
||||
|
||||
# noinspection PyProtectedMember
|
||||
def get_websocket_port():
|
||||
from platypush.backend.http import HttpBackend
|
||||
|
||||
http_conf = Config.get('backend.http') or {}
|
||||
return http_conf.get('websocket_port', HttpBackend._DEFAULT_WEBSOCKET_PORT)
|
||||
|
||||
|
||||
def send_message(msg, wait_for_response=True):
|
||||
msg = Message.build(msg)
|
||||
if msg is None:
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
<template>
|
||||
<Events ref="events" :ws-port="config['backend.http'].websocket_port" v-if="hasWebsocket" />
|
||||
<Events ref="events" v-if="hasWebsocket" />
|
||||
<Notifications ref="notifications" />
|
||||
<VoiceAssistant ref="voice-assistant" v-if="hasAssistant" />
|
||||
<Pushbullet ref="pushbullet" v-if="hasPushbullet" />
|
||||
|
|
Loading…
Reference in a new issue