From 06d14f94a998ef795c52e7950e5cc8828464ae8e Mon Sep 17 00:00:00 2001 From: Vitaly Takmazov Date: Fri, 28 Oct 2022 14:05:47 +0300 Subject: Handle profile errors --- vnext/src/api/index.js | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'vnext/src/api/index.js') diff --git a/vnext/src/api/index.js b/vnext/src/api/index.js index aa0ddc6e..a6a6208c 100644 --- a/vnext/src/api/index.js +++ b/vnext/src/api/index.js @@ -71,10 +71,13 @@ const client = axios.create({ baseURL: apiBaseUrl }); client.interceptors.request.use(config => { - let cookies = new Cookies(); - config.params = Object.assign(config.params || {}, { - hash: cookies.get('hash') - }); + if (config.url.startsWith('/')) { + // only local URLs + let cookies = new Cookies(); + config.params = Object.assign(config.params || {}, { + hash: cookies.get('hash') + }); + } return config; }); -- cgit v1.2.3