fix: attempt to fix Safari login bug (#1510)

This commit is contained in:
Nolan Lawson 2019-09-22 15:12:45 -07:00 committed by GitHub
parent 41270f9210
commit 98a4fbb96e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 1 deletions

View File

@ -40,7 +40,10 @@ async function redirectToOauth () {
instanceData.client_id,
REDIRECT_URI
)
document.location.href = oauthUrl
// setTimeout to allow the browser to *actually* save the localStorage data (fixes Safari bug apparently)
setTimeout(() => {
document.location.href = oauthUrl
}, 200)
}
export async function logInToInstance () {