Skip to content

Commit

Permalink
Removed missleading defaultValue in json config
Browse files Browse the repository at this point in the history
  • Loading branch information
anthonyraymond committed Nov 1, 2023
1 parent ad311b7 commit edcaa66
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -29,14 +29,14 @@ public AppConfiguration(
@JsonProperty(value = "simultaneousSeed", required = true) final int simultaneousSeed,
@JsonProperty(value = "client", required = true) final String client,
@JsonProperty(value = "keepTorrentWithZeroLeechers", required = true) final boolean keepTorrentWithZeroLeechers,
@JsonProperty(value = "uploadRatioTarget", defaultValue = "-1.0", required = false) final float uploadRatioTarget
@JsonProperty(value = "uploadRatioTarget", required = false) final Float uploadRatioTarget
) {
this.minUploadRate = minUploadRate;
this.maxUploadRate = maxUploadRate;
this.simultaneousSeed = simultaneousSeed;
this.client = client;
this.keepTorrentWithZeroLeechers = keepTorrentWithZeroLeechers;
this.uploadRatioTarget = uploadRatioTarget;
this.uploadRatioTarget = uploadRatioTarget == null ? -1.0f : uploadRatioTarget;

validate();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,14 +27,14 @@ public class ConfigIncomingMessage {
@JsonProperty(value = "simultaneousSeed", required = true) final Integer simultaneousSeed,
@JsonProperty(value = "client", required = true) final String client,
@JsonProperty(value = "keepTorrentWithZeroLeechers", required = true) final boolean keepTorrentWithZeroLeechers,
@JsonProperty(value = "uploadRatioTarget", defaultValue = "-1.0", required = false) final Float uploadRatioTarget
@JsonProperty(value = "uploadRatioTarget", required = false) final Float uploadRatioTarget
) {
this.minUploadRate = minUploadRate;
this.maxUploadRate = maxUploadRate;
this.simultaneousSeed = simultaneousSeed;
this.client = client;
this.keepTorrentWithZeroLeechers = keepTorrentWithZeroLeechers;
this.uploadRatioTarget = uploadRatioTarget;
this.uploadRatioTarget = uploadRatioTarget == null ? -1.0f : uploadRatioTarget;
}

public AppConfiguration toAppConfiguration() throws AppConfigurationIntegrityException {
Expand Down

0 comments on commit edcaa66

Please sign in to comment.