File tree Expand file tree Collapse file tree 3 files changed +15
-0
lines changed Expand file tree Collapse file tree 3 files changed +15
-0
lines changed Original file line number Diff line number Diff line change @@ -31,6 +31,11 @@ public PagedQuery(
31
31
Subqueries = subqueries . ToList ( ) ;
32
32
}
33
33
34
+ /// <summary>
35
+ /// Gets a value indicating whether the query is a mutation.
36
+ /// </summary>
37
+ public bool IsMutation => MasterQuery . IsMutation ;
38
+
34
39
/// <summary>
35
40
/// Gets the master query.
36
41
/// </summary>
Original file line number Diff line number Diff line change @@ -36,6 +36,11 @@ public SimpleQuery(
36
36
ResultBuilder = ExpressionCompiler . Compile ( resultBuilder ) ;
37
37
}
38
38
39
+ /// <summary>
40
+ /// Gets a value indicating whether the query is a mutation.
41
+ /// </summary>
42
+ public bool IsMutation => OperationDefinition . Type == OperationType . Mutation ;
43
+
39
44
/// <summary>
40
45
/// Gets the GraphQL operation definition.
41
46
/// </summary>
Original file line number Diff line number Diff line change @@ -9,6 +9,11 @@ namespace Octokit.GraphQL
9
9
/// </summary>
10
10
public interface ICompiledQuery
11
11
{
12
+ /// <summary>
13
+ /// Gets a value indicating whether the query is a mutation.
14
+ /// </summary>
15
+ bool IsMutation { get ; }
16
+
12
17
/// <summary>
13
18
/// Returns an <see cref="IQueryRunner"/> which can be used to run the query on a connection.
14
19
/// </summary>
You can’t perform that action at this time.
0 commit comments