We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b290cb8 commit c0b1fb8Copy full SHA for c0b1fb8
src/KSFramework/KSMessaging/Extensions/RegisterMediatorServices.cs
@@ -95,13 +95,13 @@ private static void RegisterAllImplementationsOf<TInterface>(this IServiceCollec
95
switch (lifetime)
96
{
97
case ServiceLifetime.Transient:
98
- services.AddTransient(interfaceType, implementation);
+ services.AddTransient(implementation);
99
break;
100
case ServiceLifetime.Scoped:
101
- services.AddScoped(interfaceType, implementation);
+ services.AddScoped(implementation);
102
103
case ServiceLifetime.Singleton:
104
- services.AddSingleton(interfaceType, implementation);
+ services.AddSingleton(implementation);
105
106
default:
107
throw new ArgumentException("Invalid service lifetime", nameof(lifetime));
0 commit comments