Skip to content

Commit

Permalink
add review
Browse files Browse the repository at this point in the history
  • Loading branch information
Kathrin-Huber committed May 19, 2021
1 parent 647bec4 commit 2d88500
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 26 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ public void run() {
}
while (progress < processesList.size()) {
Process process = processService.getById(processesList.get(progress));
if (fileService.processOwnsAnchorXML(process, true) && !fileService.processOwnsYearXML(process, true)) {
if (fileService.processOwnsAnchorXML(process) && !fileService.processOwnsYearXML(process)) {
setWorkDetail(process.getTitle());
migrate(process);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,7 @@ private static boolean isNewspaperBatch(Batch batch) throws IOException {
logger.trace("Examining batch {}...", batch.getTitle());
boolean newspaperBatch = true;
for (Process process : batch.getProcesses()) {
if (!fileService.processOwnsYearXML(process, true)) {
if (!fileService.processOwnsYearXML(process)) {
newspaperBatch = false;
break;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -562,18 +562,7 @@ public void moveFile(URI sourceUri, URI targetUri) throws IOException {
* if Io failed
*/
public boolean processOwnsAnchorXML(Process process) throws IOException {
return processOwnsAnchorXML(process, false);
}

/**
* Process owns anchor XML.
*
* @param process whose metadata path to use
* @param forIndexingAll if method is triggerd from system/indexing page
* @return true if anchor file was found
*/
public boolean processOwnsAnchorXML(Process process, boolean forIndexingAll) throws IOException {
URI yearFile = createAnchorFile(getMetadataFilePath(process, false, forIndexingAll));
URI yearFile = createAnchorFile(getMetadataFilePath(process, false, true));
return fileExist(yearFile);
}

Expand All @@ -587,18 +576,7 @@ public boolean processOwnsAnchorXML(Process process, boolean forIndexingAll) thr
* if Io failed
*/
public boolean processOwnsYearXML(Process process) throws IOException {
return processOwnsYearXML(process, false);
}

/**
* Process owns year XML.
*
* @param process whose metadata path to use
* @param forIndexingAll if method is triggerd from system/indexing page
* @return true if year file was found
*/
public boolean processOwnsYearXML(Process process, boolean forIndexingAll) throws IOException {
URI yearFile = createYearFile(getMetadataFilePath(process, false, forIndexingAll));
URI yearFile = createYearFile(getMetadataFilePath(process, false, true));
return fileExist(yearFile);
}

Expand Down

0 comments on commit 2d88500

Please sign in to comment.