diff --git a/src/Api/KeyManagement/Registrations.cs b/src/Api/KeyManagement/Registrations.cs deleted file mode 100644 index 76bdad4584..0000000000 --- a/src/Api/KeyManagement/Registrations.cs +++ /dev/null @@ -1,14 +0,0 @@ -using Bit.Api.KeyManagement.Queries.Interfaces; -using Bit.Core.KeyManagement.Queries; - -namespace Bit.Api.KeyManagement; - -#nullable enable - -public static class Registrations -{ - public static void AddKeyManagementQueries(this IServiceCollection services) - { - services.AddTransient(); - } -} diff --git a/src/Core/KeyManagement/KeyManagementServiceCollectionExtensions.cs b/src/Core/KeyManagement/KeyManagementServiceCollectionExtensions.cs index 102630c7e6..f53ded94dc 100644 --- a/src/Core/KeyManagement/KeyManagementServiceCollectionExtensions.cs +++ b/src/Core/KeyManagement/KeyManagementServiceCollectionExtensions.cs @@ -1,5 +1,7 @@ -using Bit.Core.KeyManagement.Commands; +using Bit.Api.KeyManagement.Queries.Interfaces; +using Bit.Core.KeyManagement.Commands; using Bit.Core.KeyManagement.Commands.Interfaces; +using Bit.Core.KeyManagement.Queries; using Microsoft.Extensions.DependencyInjection; namespace Bit.Core.KeyManagement; @@ -9,10 +11,16 @@ public static class KeyManagementServiceCollectionExtensions public static void AddKeyManagementServices(this IServiceCollection services) { services.AddKeyManagementCommands(); + services.AddKeyManagementQueries(); } private static void AddKeyManagementCommands(this IServiceCollection services) { services.AddScoped(); } + + private static void AddKeyManagementQueries(this IServiceCollection services) + { + services.AddScoped(); + } }