3
0
Mirror von https://github.com/ViaVersion/ViaVersion.git synchronisiert 2024-11-03 14:50:30 +01:00

Remove redundant/already implicit check in VersionRange

Dieser Commit ist enthalten in:
KennyTV 2020-10-24 22:39:17 +02:00
Ursprung bc2f6a423f
Commit 2f9ec6f2aa
Es konnte kein GPG-Schlüssel zu dieser Signatur gefunden werden
GPG-Schlüssel-ID: 6BE3B555EBC5982B

Datei anzeigen

@ -12,12 +12,12 @@ public class VersionRange {
* *
* @param baseVersion base version * @param baseVersion base version
* @param rangeFrom minor version the range begins at, must be greater than or equal to 0 * @param rangeFrom minor version the range begins at, must be greater than or equal to 0
* @param rangeTo minor version the range ends at, must be greater than 0 and {@link #rangeFrom} * @param rangeTo minor version the range ends at, must be greater than {@code rangeFrom}
*/ */
public VersionRange(String baseVersion, int rangeFrom, int rangeTo) { public VersionRange(String baseVersion, int rangeFrom, int rangeTo) {
Preconditions.checkNotNull(baseVersion); Preconditions.checkNotNull(baseVersion);
Preconditions.checkArgument(rangeFrom >= 0); Preconditions.checkArgument(rangeFrom >= 0);
Preconditions.checkArgument(rangeTo > rangeFrom && rangeTo > 0); Preconditions.checkArgument(rangeTo > rangeFrom);
this.baseVersion = baseVersion; this.baseVersion = baseVersion;
this.rangeFrom = rangeFrom; this.rangeFrom = rangeFrom;
this.rangeTo = rangeTo; this.rangeTo = rangeTo;