File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed
HMCLCore/src/main/java/org/jackhuang/hmcl/download/game Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change 2424import org .jackhuang .hmcl .game .Version ;
2525import org .jackhuang .hmcl .task .Task ;
2626import org .jackhuang .hmcl .util .Immutable ;
27+ import org .jackhuang .hmcl .util .versioning .GameVersionNumber ;
2728
2829import java .time .Instant ;
2930import java .util .List ;
@@ -56,7 +57,12 @@ public int compareTo(RemoteVersion o) {
5657 if (!(o instanceof GameRemoteVersion ))
5758 return 0 ;
5859
59- return o .getReleaseDate ().compareTo (getReleaseDate ());
60+ int dateCompare = o .getReleaseDate ().compareTo (getReleaseDate ());
61+ if (dateCompare != 0 ) {
62+ return dateCompare ;
63+ }
64+
65+ return GameVersionNumber .compare (getSelfVersion (), o .getSelfVersion ());
6066 }
6167
6268 private static Type getReleaseType (ReleaseType type ) {
You can’t perform that action at this time.
0 commit comments