Skip to content

Commit

Permalink
Fix BoostersResponse deserialization
Browse files Browse the repository at this point in the history
  • Loading branch information
Citrinate committed Mar 3, 2024
1 parent 7d9f2bc commit d60bcbf
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion BoosterManager/Json.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ internal class EResultResponse {
[JsonInclude]
[JsonPropertyName("success")]
[JsonRequired]
public readonly EResult Result;
public EResult Result { get; private init; }

[JsonConstructor]
public EResultResponse() { }
Expand Down Expand Up @@ -56,16 +56,19 @@ public BoosterInfo() { }
internal sealed class BoostersResponse {
[JsonInclude]
[JsonPropertyName("goo_amount")]
[JsonNumberHandling(JsonNumberHandling.AllowReadingFromString)]
[JsonRequired]
internal uint GooAmount { get; private init; }

[JsonInclude]
[JsonPropertyName("tradable_goo_amount")]
[JsonNumberHandling(JsonNumberHandling.AllowReadingFromString)]
[JsonRequired]
internal uint TradableGooAmount { get; private init; }

[JsonInclude]
[JsonPropertyName("untradable_goo_amount")]
[JsonNumberHandling(JsonNumberHandling.AllowReadingFromString)]
[JsonRequired]
internal uint UntradableGooAmount { get; private init; }

Expand Down

0 comments on commit d60bcbf

Please sign in to comment.