From f213a8e094eebde56b85f783f58c0ce961e70eed Mon Sep 17 00:00:00 2001 From: Lim Chee Aun Date: Tue, 12 Dec 2023 08:34:43 +0800 Subject: [PATCH] Fix subfolder hosting not working Fix wrong `location` used --- src/app.jsx | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/app.jsx b/src/app.jsx index dc46bb45..3e4a6879 100644 --- a/src/app.jsx +++ b/src/app.jsx @@ -261,7 +261,11 @@ function App() { if (code) { console.log({ code }); // Clear the code from the URL - window.history.replaceState({}, document.title, location.pathname || '/'); + window.history.replaceState( + {}, + document.title, + window.location.pathname || '/', + ); const clientID = store.session.get('clientID'); const clientSecret = store.session.get('clientSecret');