Skip to content

Commit 8f9237c

Browse files
authored
add null check for protocol AppMetadata assignment
1 parent e62fdd3 commit 8f9237c

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

csharp/src/Apache.Arrow.Flight/FlightInfo.cs

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -76,10 +76,14 @@ internal Protocol.FlightInfo ToProtocol()
7676
FlightDescriptor = Descriptor.ToProtocol(),
7777
TotalBytes = TotalBytes,
7878
TotalRecords = TotalRecords,
79-
Ordered = Ordered,
80-
AppMetadata = AppMetadata
79+
Ordered = Ordered
8180
};
8281

82+
if (AppMetadata != null)
83+
{
84+
response.AppMetadata = AppMetadata;
85+
}
86+
8387
foreach(var endpoint in Endpoints)
8488
{
8589
response.Endpoint.Add(endpoint.ToProtocol());

0 commit comments

Comments
 (0)