diff --git a/src/util/Util.js b/src/util/Util.js index 2a6f4f0..f50b512 100644 --- a/src/util/Util.js +++ b/src/util/Util.js @@ -46,7 +46,9 @@ const parseResponse = async (response) => { if (status === 401) { clearSession(); - if(!location.pathname.includes('/login') && !location.pathname.includes('/register')) location.pathname = '/login'; + if (!location.pathname.includes('/login') + && !location.pathname.includes('/register') + && location.pathname !== '/') location.pathname = '/login'; } if (headers['content-type']?.includes('application/json')) {