Skip to content

Commit

Permalink
Avoid empty if statements
Browse files Browse the repository at this point in the history
  • Loading branch information
LinusDietz committed Feb 15, 2018
1 parent fe26823 commit 8359015
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -328,13 +328,13 @@ public void writeXMPMetadata() {
Optional<Path> file = linkedFile.findIn(databaseContext, Globals.prefs.getFileDirectoryPreferences());
if (!file.isPresent()) {
// TODO: Print error message
// Localization.lang("PDF does not exist");
LOGGER.warn("PDF does not exist!");
} else {
try {
XMPUtil.writeXMP(file.get(), entry, databaseContext.getDatabase(), Globals.prefs.getXMPPreferences());
} catch (IOException | TransformerException ex) {
// TODO: Print error message
// Localization.lang("Error while writing") + " '" + file.toString() + "': " + ex;
LOGGER.warn("Error while writing" + " '" + file.toString() + "': " + ex);
}
}
return null;
Expand Down

0 comments on commit 8359015

Please sign in to comment.