From c0a948f8ce87848baab374a24025f696cc4d0996 Mon Sep 17 00:00:00 2001 From: Fabio Manganiello Date: Sun, 7 May 2023 12:54:13 +0200 Subject: [PATCH] Removed remaining references to websocket port. --- platypush/backend/http/app/routes/dashboard.py | 11 ++++++----- platypush/backend/http/app/utils.py | 8 -------- platypush/backend/http/webapp/src/App.vue | 2 +- 3 files changed, 7 insertions(+), 14 deletions(-) diff --git a/platypush/backend/http/app/routes/dashboard.py b/platypush/backend/http/app/routes/dashboard.py index 68d1f06dab..e6f7b1f5b5 100644 --- a/platypush/backend/http/app/routes/dashboard.py +++ b/platypush/backend/http/app/routes/dashboard.py @@ -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) @@ -16,10 +16,11 @@ __routes__ = [ @dashboard.route('/dashboard/', methods=['GET']) @authenticate() def render_dashboard(name): - """ Route for the dashboard """ - return render_template('index.html', - utils=HttpUtils, - websocket_port=get_websocket_port()) + """Route for the dashboard""" + return render_template( + 'index.html', + utils=HttpUtils, + ) # vim:sw=4:ts=4:et: diff --git a/platypush/backend/http/app/utils.py b/platypush/backend/http/app/utils.py index bd1f393258..537775045c 100644 --- a/platypush/backend/http/app/utils.py +++ b/platypush/backend/http/app/utils.py @@ -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: diff --git a/platypush/backend/http/webapp/src/App.vue b/platypush/backend/http/webapp/src/App.vue index 0ac9269226..bc48a6ea0d 100644 --- a/platypush/backend/http/webapp/src/App.vue +++ b/platypush/backend/http/webapp/src/App.vue @@ -1,5 +1,5 @@