Skip to content

Commit

Permalink
Fix: throw error when authorized without email
Browse files Browse the repository at this point in the history
  • Loading branch information
leon-zhang-awx committed May 6, 2024
1 parent f85b5b8 commit 1c10da2
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -211,6 +211,9 @@ define(

if (!utils.isLoggedIn()) {
payload.email = utils.isCheckoutPage() ? $(utils.guestEmailSelector).val() : this.guestEmail;
if (!payload.email) {
throw new Error('Email is required!');
}
}

const intentResponse = await storage.post(
Expand Down

0 comments on commit 1c10da2

Please sign in to comment.