Must decode the code!

This commit is contained in:
Lim Chee Aun 2023-05-20 10:08:41 +08:00
parent 3acaac2d47
commit bcd91851d2

View file

@ -91,7 +91,9 @@ function App() {
useEffect(() => {
const instanceURL = store.local.get('instanceURL');
const code = (window.location.search.match(/code=([^&]+)/) || [])[1];
const code = decodeURIComponent(
(window.location.search.match(/code=([^&]+)/) || [, ''])[1],
);
if (code) {
console.log({ code });