Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/main'
Browse files Browse the repository at this point in the history
  • Loading branch information
calixtus committed Dec 23, 2024
2 parents 8b532f6 + 0892724 commit 85fa800
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/main/java/org/jabref/gui/linkedfile/DeleteFileAction.java
Original file line number Diff line number Diff line change
Expand Up @@ -98,10 +98,16 @@ public void execute() {
Path path = file.get();
dialogTitle = Localization.lang("Delete '%0'", path.getFileName().toString());
} else {
LOGGER.warn("Could not find file {}", linkedFile.getLink());
dialogService.notify(Localization.lang("Error accessing file '%0'.", linkedFile.getLink()));

// We can trigger deletion of "all" files from the entry (no deletion on disk), because in this case, there is only one files
assert numberOfLinkedFiles == 1;
deleteFiles(false);

// Deleting a non-existing file is a success
success = true;

return;
}
}
Expand Down

0 comments on commit 85fa800

Please sign in to comment.