Respect base URL in WS connections

This commit is contained in:
Alex Ling 2021-01-11 15:05:58 +00:00
parent 4645582f5d
commit 5271d12f4c

View File

@ -6,7 +6,7 @@ const component = () => {
toggling: false, toggling: false,
init() { init() {
const ws = new WebSocket(`ws://${location.host}/api/admin/mangadex/queue`); const ws = new WebSocket(`ws://${location.host}${base_url}api/admin/mangadex/queue`);
ws.onmessage = event => { ws.onmessage = event => {
const data = JSON.parse(event.data); const data = JSON.parse(event.data);
this.jobs = data.jobs; this.jobs = data.jobs;