Skip to content

Commit

Permalink
Remove nullable
Browse files Browse the repository at this point in the history
  • Loading branch information
adam.gloyne committed Sep 3, 2024
1 parent b04e9a8 commit b74e620
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/LEGO.AsyncAPI.Bindings/Sns/Statement.cs
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ public class Statement : IAsyncApiExtensible
/// <summary>
/// Specific circumstances under which the policy grants permission.
/// </summary>
public Condition? Condition { get; set; }
public Condition Condition { get; set; }

public IDictionary<string, IAsyncApiExtension> Extensions { get; set; } = new Dictionary<string, IAsyncApiExtension>();

Expand All @@ -49,7 +49,7 @@ public void Serialize(IAsyncApiWriter writer)
writer.WriteRequiredObject("principal", this.Principal, (w, t) => t.Serialize(w));
writer.WriteRequiredObject("action", this.Action, (w, t) => t.Value.Write(w));
writer.WriteOptionalObject("resource", this.Resource, (w, t) => t?.Value.Write(w));
writer.WriteOptionalObject("condition", this.Condition, (w, t) => t?.Serialize(w));
writer.WriteOptionalObject("condition", this.Condition, (w, t) => t.Serialize(w));
writer.WriteExtensions(this.Extensions);
writer.WriteEndObject();
}
Expand Down
4 changes: 2 additions & 2 deletions src/LEGO.AsyncAPI.Bindings/Sqs/Statement.cs
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ public class Statement : IAsyncApiExtensible
/// <summary>
/// Specific circumstances under which the policy grants permission.
/// </summary>
public Condition? Condition { get; set; }
public Condition Condition { get; set; }

public IDictionary<string, IAsyncApiExtension> Extensions { get; set; } = new Dictionary<string, IAsyncApiExtension>();

Expand All @@ -50,7 +50,7 @@ public void Serialize(IAsyncApiWriter writer)
writer.WriteRequiredObject("principal", this.Principal, (w, t) => t.Serialize(w));
writer.WriteRequiredObject("action", this.Action, (w, t) => t.Value.Write(w));
writer.WriteOptionalObject("resource", this.Resource, (w, t) => t?.Value.Write(w));
writer.WriteOptionalObject("condition", this.Condition, (w, t) => t?.Serialize(w));
writer.WriteOptionalObject("condition", this.Condition, (w, t) => t.Serialize(w));
writer.WriteExtensions(this.Extensions);
writer.WriteEndObject();
}
Expand Down

0 comments on commit b74e620

Please sign in to comment.