From b5a7c4779f1e98a7440b4ca693b2b8afa1f75c39 Mon Sep 17 00:00:00 2001 From: Radek Date: Sat, 17 Mar 2018 22:26:32 +0100 Subject: [PATCH] Fixed inspections and quick fixes registration in Castle Windsor --- Rubberduck.Main/Root/RubberduckIoCInstaller.cs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/Rubberduck.Main/Root/RubberduckIoCInstaller.cs b/Rubberduck.Main/Root/RubberduckIoCInstaller.cs index 83f6e6952a..7a7855ba38 100644 --- a/Rubberduck.Main/Root/RubberduckIoCInstaller.cs +++ b/Rubberduck.Main/Root/RubberduckIoCInstaller.cs @@ -244,8 +244,7 @@ private void RegisterQuickFixes(IWindsorContainer container, Assembly[] assembli container.Register(Classes.FromAssembly(assembly) .IncludeNonPublicTypes() .Where(type => type.IsBasedOn(typeof(IQuickFix)) && type.NotDisabledExperimental(_initialSettings)) - .WithService.Base() - .WithService.Self() + .WithService.Select(new[] {typeof(IQuickFix)}) .LifestyleSingleton()); } } @@ -257,7 +256,7 @@ private void RegisterInspections(IWindsorContainer container, Assembly[] assembl container.Register(Classes.FromAssembly(assembly) .IncludeNonPublicTypes() .Where(type => type.IsBasedOn(typeof(IInspection)) && type.NotDisabledExperimental(_initialSettings)) - .WithService.Base() + .WithService.Select(new[] { typeof(IInspection) }) .LifestyleTransient()); } } @@ -269,7 +268,6 @@ private void RegisterParseTreeInspections(IWindsorContainer container, Assembly[ container.Register(Classes.FromAssembly(assembly) .IncludeNonPublicTypes() .Where(type => type.IsBasedOn(typeof(IParseTreeInspection)) && type.NotDisabledExperimental(_initialSettings)) - .WithService.Base() .WithService.Select(new[] { typeof(IInspection) }) .LifestyleTransient()); }