Skip to content

Commit 306f3da

Browse files
committed
fix(thirdweb): resolve occasional iframe error during OAuth login (#3903)
### TL;DR Fix occasional iframe error when logging in with oauth ### What changed? Removed error throwing for invalid event type in OAuth login flow. ### How to test? Attempt OAuth login and ensure no errors occur related to iframes. ### Why make this change? To prevent unnecessary exceptions which impede the OAuth login user experience. ---
1 parent e6495c1 commit 306f3da

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

.changeset/unlucky-news-tease.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"thirdweb": patch
3+
---
4+
5+
Fix occasional iframe error when logging in with oauth

packages/thirdweb/src/wallets/in-app/web/lib/auth/oauth.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ export const loginWithOauth = async (options: {
111111
break;
112112
}
113113
default: {
114-
reject(new Error(`Invalid event type: ${event.data.eventType}`));
114+
// no-op, DO NOT THROW HERE
115115
}
116116
}
117117
};

0 commit comments

Comments
 (0)