Skip to content

Commit

Permalink
fix(errors): fix error handling when deleting documents
Browse files Browse the repository at this point in the history
  • Loading branch information
anehx committed Jun 24, 2024
1 parent 4af3936 commit 6d220d5
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion addon/components/document-delete-button.js
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,9 @@ export default class DocumentDeleteButtonComponent extends Component {

rejected.forEach((error, index) => {
docs[index].rollbackAttributes();
new ErrorHandler(this, error).notify("alexandria.errors.delete-document");
new ErrorHandler(this, error.reason).notify(
"alexandria.errors.delete-document",
);
});

if (!rejected.length) {
Expand Down

0 comments on commit 6d220d5

Please sign in to comment.