Skip to content

Commit

Permalink
Fix expired JWT auth fail pre refresh
Browse files Browse the repository at this point in the history
  • Loading branch information
WietseWind committed May 16, 2023
1 parent b0dcea0 commit 88785e8
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -427,7 +427,11 @@ export class XummPkceThread extends EventEmitter {

this.resolved = false;

await this.ping
try {
await this.ping
} catch (e) {
// Nope (prevent 401 error from API to bleed into auth flow)
}

if (!this.mobileRedirectFlow && !this.autoResolvedFlow) {
const url = this.authorizeUrl();
Expand Down

0 comments on commit 88785e8

Please sign in to comment.