Skip to content

Commit 07b9b4e

Browse files
authored
Fixed removes necessary generic to set state on IOperation (#8519)
1 parent 726f05d commit 07b9b4e

File tree

2 files changed

+2
-5
lines changed

2 files changed

+2
-5
lines changed

src/HotChocolate/Core/src/Execution/Processing/Operation.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ public TState GetOrAddState<TState, TContext>(Func<TContext, TState> createState
155155
return (TState)state!;
156156
}
157157

158-
public TState GetOrAddState<TState, TContext>(
158+
public TState GetOrAddState<TState>(
159159
string key,
160160
Func<string, TState> createState)
161161
=> GetOrAddState<TState, object?>(key, (k, _) => createState(k), null);

src/HotChocolate/Core/src/Types/Execution/Processing/IOperation.cs

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -153,9 +153,6 @@ TState GetOrAddState<TState, TContext>(
153153
/// <typeparam name="TState">
154154
/// The type of the state.
155155
/// </typeparam>
156-
/// <typeparam name="TContext">
157-
/// The type of the context.
158-
/// </typeparam>
159156
/// <param name="key">
160157
/// The key of the state.
161158
/// </param>
@@ -165,7 +162,7 @@ TState GetOrAddState<TState, TContext>(
165162
/// <returns>
166163
/// Returns the state.
167164
/// </returns>
168-
TState GetOrAddState<TState, TContext>(
165+
TState GetOrAddState<TState>(
169166
string key,
170167
Func<string, TState> createState);
171168

0 commit comments

Comments
 (0)