diff --git a/app/js/client.es6.js b/app/js/client.es6.js index 719d6539..3d7bae9a 100644 --- a/app/js/client.es6.js +++ b/app/js/client.es6.js @@ -58,7 +58,7 @@ export default class Client { }) this.socket.on('download', (data) => { - window.location = `${config.server_host}:${config.server_port}/v1/downloads?package=${data.package}&module=${data.module}` + window.location = `/v1/downloads?package=${data.package}&module=${data.module}` }) if (this.history !== null) { diff --git a/app/js/main.es6.js b/app/js/main.es6.js index 0d4dca67..aa4d2efb 100644 --- a/app/js/main.es6.js +++ b/app/js/main.es6.js @@ -21,7 +21,7 @@ document.addEventListener('DOMContentLoaded', () => { loader.start() - request.get(`${config.server_host}:${config.server_port}/v1/info`) + request.get('/v1/info') .end((err, res) => { if (err || !res.ok) { console.error(err.response.error.message) diff --git a/hotword/index.js b/hotword/index.js index 3268b577..7115c3e0 100644 --- a/hotword/index.js +++ b/hotword/index.js @@ -21,7 +21,7 @@ socket.on('connect', () => { console.log('Waiting for hotword...') }) -request.get(`${url}/v1/info`) +request.get('/v1/info') .end((err, res) => { if (err || !res.ok) { if (!err.response) {