aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/web/src/config.js4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/web/src/config.js b/src/web/src/config.js
index 4d6522e3..bd05aea5 100644
--- a/src/web/src/config.js
+++ b/src/web/src/config.js
@@ -1,4 +1,5 @@
-const baseUrl = process.env.NODE_ENV === 'production' ? 'api/v0' : 'http://localhost:5000/api/v0';
+const rootUrl = process.env.NODE_ENV === 'production' ? '' : 'http://localhost:5000';
+const baseUrl = `${rootUrl}/api/v0`;
const tokenKey = 'slskd-token';
const tokenPassthroughValue = 'n/a';
const activeChatKey = 'slskd-active-chat';
@@ -6,6 +7,7 @@ const activeRoomKey = 'slskd-active-room';
const activeUserInfoKey = 'slskd-active-user';
export {
+ rootUrl,
baseUrl,
tokenKey,
tokenPassthroughValue,