1
0
mirror of https://github.com/bitwarden/browser.git synced 2024-09-21 03:11:27 +02:00

add basic error handling

This commit is contained in:
jaasen-livefront 2024-09-20 16:45:27 -07:00
parent 13ba396e53
commit f97a089106
No known key found for this signature in database

View File

@ -112,10 +112,19 @@ export class SendAddEditComponent {
});
if (!confirmed) {
return false;
return;
}
await this.sendApiService.delete(this.config.originalSend?.id);
try {
await this.sendApiService.delete(this.config.originalSend?.id);
} catch (e) {
this.toastService.showToast({
variant: "error",
title: null,
message: e.message,
});
return;
}
this.location.back();