Skip to content

Commit

Permalink
send notification on purchase/checkout failure
Browse files Browse the repository at this point in the history
  • Loading branch information
laur89 committed Feb 5, 2025
1 parent b25ea9e commit 1a50eaa
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -58,11 +58,11 @@ export async function redeemAccount(account: AccountConfig): Promise<void> {
}
} catch (e) {
if (e.response) {
if (e.response.body) L.error(e.response.body);
else L.error(e.response);
L.error(e.response.body ?? e.response);
}
L.error(e);
logVersionOnError();
await sendNotification(account.email, NotificationReason.PURCHASE_ERROR);
}
}

Expand Down

0 comments on commit 1a50eaa

Please sign in to comment.