1
0
Fork 0

code review

This commit is contained in:
Xavier Fontanet 2024-05-19 17:44:12 +02:00
parent 978a80b9dc
commit af9478cd64
1 changed files with 2 additions and 2 deletions

View File

@ -16,7 +16,7 @@ public class MissingFilesDetector {
return; return;
torrentFileLengths.keySet().forEach(fileSize -> torrentFileLengths.keySet().forEach(fileSize ->
takeDecisionForComparing(fileSize, torrentFileLengths)); takeDecisionForMismatch(fileSize, torrentFileLengths));
} }
@ -42,7 +42,7 @@ public class MissingFilesDetector {
return false; return false;
} }
void takeDecisionForComparing(Long fileSize, Map<Long, List<Path>> torrentFileLengths) { void takeDecisionForMismatch(Long fileSize, Map<Long, List<Path>> torrentFileLengths) {
var alreadyExists = torrentFileLengths.containsKey(fileSize); var alreadyExists = torrentFileLengths.containsKey(fileSize);
if (!alreadyExists) { if (!alreadyExists) {
System.out.printf("- needs to copy %s%n", torrentFileLengths.get(fileSize)); System.out.printf("- needs to copy %s%n", torrentFileLengths.get(fileSize));