diff --git a/src/OrchardCore/OrchardCore.Apis.GraphQL.Abstractions/ServiceCollectionExtensions.cs b/src/OrchardCore/OrchardCore.Apis.GraphQL.Abstractions/ServiceCollectionExtensions.cs index 3cb116e7f2b..ca5a2c72663 100644 --- a/src/OrchardCore/OrchardCore.Apis.GraphQL.Abstractions/ServiceCollectionExtensions.cs +++ b/src/OrchardCore/OrchardCore.Apis.GraphQL.Abstractions/ServiceCollectionExtensions.cs @@ -15,7 +15,7 @@ public static void AddInputObjectGraphType(this IServiceCo where TObject : class where TObjectType : InputObjectGraphType { - services.AddScoped(); + services.AddTransient(); services.AddTransient, TObjectType>(s => s.GetRequiredService()); services.AddTransient(s => s.GetRequiredService()); } @@ -30,7 +30,7 @@ public static void AddObjectGraphType(this IServiceCollectio where TInput : class where TInputType : ObjectGraphType { - services.AddScoped(); + services.AddTransient(); services.AddTransient, TInputType>(s => s.GetRequiredService()); services.AddTransient(s => s.GetRequiredService()); }