Skip to content

Commit

Permalink
JetStream config JSON fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
mtmk committed Feb 12, 2024
1 parent 620581b commit c79f22a
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions src/NATS.Client.JetStream/Models/Placement.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,12 @@ public record Placement
/// The desired cluster name to place the stream
/// </summary>
[System.Text.Json.Serialization.JsonPropertyName("cluster")]
[System.Text.Json.Serialization.JsonIgnore(Condition = System.Text.Json.Serialization.JsonIgnoreCondition.Never)]
[System.ComponentModel.DataAnnotations.Required(AllowEmptyStrings = true)]
[System.Text.Json.Serialization.JsonIgnore(Condition = System.Text.Json.Serialization.JsonIgnoreCondition.WhenWritingNull)]
#if NET6_0
public string Cluster { get; set; } = default!;
public string? Cluster { get; set; } = default;
#else
#pragma warning disable SA1206
public required string Cluster { get; set; }
public string? Cluster { get; set; }
#pragma warning restore SA1206
#endif

Expand Down

0 comments on commit c79f22a

Please sign in to comment.