File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed
HMCLCore/src/main/java/org/jackhuang/hmcl/mod Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -302,11 +302,13 @@ public Map<String, String> getHashes() {
302302
303303 public FileDownloadTask .IntegrityCheck getIntegrityCheck () {
304304 if (hashes .containsKey ("md5" )) {
305- return new FileDownloadTask .IntegrityCheck ("MD5" , hashes .get ("sha1 " ));
305+ return new FileDownloadTask .IntegrityCheck ("MD5" , hashes .get ("md5 " ));
306306 } else if (hashes .containsKey ("sha1" )) {
307307 return new FileDownloadTask .IntegrityCheck ("SHA-1" , hashes .get ("sha1" ));
308+ } else if (hashes .containsKey ("sha256" )) {
309+ return new FileDownloadTask .IntegrityCheck ("SHA-256" , hashes .get ("sha256" ));
308310 } else if (hashes .containsKey ("sha512" )) {
309- return new FileDownloadTask .IntegrityCheck ("SHA-256 " , hashes .get ("sha1 " ));
311+ return new FileDownloadTask .IntegrityCheck ("SHA-512 " , hashes .get ("sha512 " ));
310312 } else {
311313 return null ;
312314 }
You can’t perform that action at this time.
0 commit comments