Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(files_trashbin): Allow preventing trash to be deleted permanently #50077

Merged
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fix(files_trashbin): Only emit files:node:deleted events if deleting …
…all trash was successful

Signed-off-by: provokateurin <kate@provokateurin.de>
  • Loading branch information
provokateurin committed Jan 13, 2025
commit badf6ab9359f548c6288877da1f84cde51f3d99c
5 changes: 3 additions & 2 deletions apps/files_trashbin/src/fileListActions/emptyTrashAction.ts
Original file line number Diff line number Diff line change
@@ -82,8 +82,9 @@ export const emptyTrashAction = new FileListAction({

const result = await askConfirmation
if (result === true) {
await emptyTrash()
nodes.forEach((node) => emit('files:node:deleted', node))
if (await emptyTrash()) {
nodes.forEach((node) => emit('files:node:deleted', node))
}
return
}