Skip to content

Commit

Permalink
Merge pull request #12334 from JabRef/follow-up-12324
Browse files Browse the repository at this point in the history
Refine comments
  • Loading branch information
Siedlerchr authored Dec 23, 2024
2 parents d4624f7 + f82c5ab commit 0892724
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 0892724

Please sign in to comment.