Skip to content

Commit 2dd397d

Browse files
committed
use Dictionary copy constructor on new GraphQLRequest constructor
1 parent 840da16 commit 2dd397d

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

src/GraphQL.Primitives/GraphQLRequest.cs

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -49,13 +49,7 @@ public GraphQLRequest(string query, object? variables = null, string? operationN
4949
OperationName = operationName;
5050
}
5151

52-
public GraphQLRequest(GraphQLRequest other)
53-
{
54-
foreach(var kv in other)
55-
{
56-
Add(kv.Key, kv.Value);
57-
}
58-
}
52+
public GraphQLRequest(GraphQLRequest other): base(other) { }
5953

6054
/// <summary>
6155
/// Returns a value that indicates whether this instance is equal to a specified object

0 commit comments

Comments
 (0)