Skip to content

Commit 9a05a2d

Browse files
committed
update
1 parent b5025a0 commit 9a05a2d

1 file changed

Lines changed: 11 additions & 11 deletions

File tree

HMCLCore/src/main/java/org/jackhuang/hmcl/mod/RemoteMod.java

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -167,17 +167,17 @@ public record Version(IVersion self, String modid, String name, String version,
167167

168168
public record File(Map<String, String> hashes, String url, String filename) {
169169
public FileDownloadTask.IntegrityCheck getIntegrityCheck() {
170-
if (hashes.containsKey("md5")) {
171-
return new FileDownloadTask.IntegrityCheck("MD5", hashes.get("md5"));
172-
} else if (hashes.containsKey("sha1")) {
173-
return new FileDownloadTask.IntegrityCheck("SHA-1", hashes.get("sha1"));
174-
} else if (hashes.containsKey("sha256")) {
175-
return new FileDownloadTask.IntegrityCheck("SHA-256", hashes.get("sha256"));
176-
} else if (hashes.containsKey("sha512")) {
177-
return new FileDownloadTask.IntegrityCheck("SHA-512", hashes.get("sha512"));
178-
} else {
179-
return null;
180-
}
170+
if (hashes.containsKey("md5")) {
171+
return new FileDownloadTask.IntegrityCheck("MD5", hashes.get("md5"));
172+
} else if (hashes.containsKey("sha1")) {
173+
return new FileDownloadTask.IntegrityCheck("SHA-1", hashes.get("sha1"));
174+
} else if (hashes.containsKey("sha256")) {
175+
return new FileDownloadTask.IntegrityCheck("SHA-256", hashes.get("sha256"));
176+
} else if (hashes.containsKey("sha512")) {
177+
return new FileDownloadTask.IntegrityCheck("SHA-512", hashes.get("sha512"));
178+
} else {
179+
return null;
181180
}
182181
}
182+
}
183183
}

0 commit comments

Comments
 (0)