Skip to content

Commit 54eb2a9

Browse files
committed
chore: switch #validateRedirectUrl back to a sync method
1 parent 6f9a4a8 commit 54eb2a9

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

packages/keyring-snap-bridge/src/SnapKeyring.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -577,7 +577,7 @@ export class SnapKeyring extends EventEmitter {
577577
): Promise<void> {
578578
const { message = '', url = '' } = redirect;
579579
if (url) {
580-
await this.#validateRedirectUrl(url, snapId);
580+
this.#validateRedirectUrl(url, snapId);
581581
}
582582
await this.#callbacks.redirectUser(snapId, url, message);
583583
}
@@ -589,7 +589,7 @@ export class SnapKeyring extends EventEmitter {
589589
* @param snapId - The Snap ID to check allowed origins for.
590590
* @throws An error if the URL's origin is not in the Snap's allowed origins.
591591
*/
592-
async #validateRedirectUrl(url: string, snapId: SnapId): Promise<void> {
592+
#validateRedirectUrl(url: string, snapId: SnapId): void {
593593
const { origin } = new URL(url);
594594
const snap = this.#snapClient.getController().get(snapId);
595595
if (!snap) {

0 commit comments

Comments
 (0)