fix: preserve search params with leading question mark

This commit is contained in:
EnixCoda 2021-05-24 21:12:07 +08:00
parent aa0f59c90b
commit 659fa2122b
No known key found for this signature in database
GPG key ID: 0C1A07377913A1DD

View file

@ -59,7 +59,7 @@ async function getAccessTokenWithCode(code: string) {
window.history.replaceState(
{},
'removed search param',
window.location.pathname.replace(window.location.search, search.toString()),
window.location.pathname.replace(window.location.search, '?' + search.toString()),
)
return accessToken
}