Skip to content

Commit

Permalink
cahange back
Browse files Browse the repository at this point in the history
  • Loading branch information
BenediktMeierUIT committed Mar 12, 2024
1 parent 6b921d1 commit 556b58d
Showing 1 changed file with 3 additions and 11 deletions.
14 changes: 3 additions & 11 deletions src/main/java/edu/harvard/iq/dataverse/DatasetServiceBean.java
Original file line number Diff line number Diff line change
Expand Up @@ -710,15 +710,11 @@ public void exportAllDatasets(boolean forceReExport) {
fileHandlerSuceeded = true;
} catch (IOException | SecurityException ex) {
Logger.getLogger(DatasetServiceBean.class.getName()).log(Level.SEVERE, null, ex);
fileHandlerSuceeded = false;
return;
}

if (fileHandlerSuceeded) {
try {
exportLogger.addHandler(fileHandler);
} catch (Exception) {
Logger.getLogger(DatasetServiceBean.class.getName()).log(Level.SEVERE, null, ex);
}
exportLogger.addHandler(fileHandler);
} else {
exportLogger = logger;
}
Expand Down Expand Up @@ -763,11 +759,7 @@ public void exportAllDatasets(boolean forceReExport) {
exportLogger.info("Finished export-all job.");

if (fileHandlerSuceeded) {
try {
fileHandler.close();
} catch (Exception) {
Logger.getLogger(DatasetServiceBean.class.getName()).log(Level.SEVERE, null, ex);
}
fileHandler.close();
}

}
Expand Down

0 comments on commit 556b58d

Please sign in to comment.