You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This code is required to resolve IServiceCollection for ModuleInitializer class and then pass to modules. Without this line, DI throws exception. Maybe code can be improved but let's keep it as is.
Unhandled exception. System.InvalidOperationException: Unable to resolve service for type 'Microsoft.Extensions.DependencyInjection.IServiceCollection' while attempting to activate 'VirtoCommerce.Platform.Modules.ModuleInitializer'.
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteFactory.CreateArgumentCallSites(ServiceIdentifier serviceIdentifier, Type implementationType, CallSiteChain callSiteChain, ParameterInfo[] parameters, Boolean throwIfCallSiteNotFound)
...
at VirtoCommerce.Platform.Modules.ServiceCollectionExtensions.AddModules(IServiceCollection services, IMvcBuilder mvcBuilder, Action`1 setupAction) in C:\Projects\git\VirtoCommerce\vc-platform\src\VirtoCommerce.Platform.Web\Extensions\ServiceCollectionExtensions.cs:line 33
...
Hi, is there any reason the platform registers the DI service collection in itself? This feels very weird...
vc-platform/src/VirtoCommerce.Platform.Web/Extensions/ServiceCollectionExtensions.cs
Line 18 in ddce0c9
The text was updated successfully, but these errors were encountered: