From aea48017a77cfe3af2c3ebfceff044beebbe9186 Mon Sep 17 00:00:00 2001 From: "Simon G." Date: Tue, 2 Dec 2025 15:02:14 +0100 Subject: [PATCH] - don't need to use factoryHelper anymore --- LightweightIocContainer.FactoryGenerator/FactoryGenerator.cs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/LightweightIocContainer.FactoryGenerator/FactoryGenerator.cs b/LightweightIocContainer.FactoryGenerator/FactoryGenerator.cs index 3d63744..c2f9b0d 100644 --- a/LightweightIocContainer.FactoryGenerator/FactoryGenerator.cs +++ b/LightweightIocContainer.FactoryGenerator/FactoryGenerator.cs @@ -112,7 +112,6 @@ public class FactoryGenerator : IIncrementalGenerator stringBuilder.AppendLine(); stringBuilder.AppendLine("using LightweightIocContainer.Interfaces.Factories;"); - stringBuilder.AppendLine("using LightweightIocContainer.Factories;"); foreach (string typeNamespace in GetNamespacesOfTypes(types)) stringBuilder.AppendLine($"using {typeNamespace};"); @@ -137,7 +136,7 @@ public class FactoryGenerator : IIncrementalGenerator stringBuilder.AppendLine($"{INDENT}{INDENT}if (typeof(TFactory) == typeof({type.Name}))"); stringBuilder.AppendLine($"{INDENT}{INDENT}{{"); - stringBuilder.AppendLine($"{INDENT}{INDENT}{INDENT}return (TFactory) (object) new Generated{type.Name}(container, new FactoryHelper());"); + stringBuilder.AppendLine($"{INDENT}{INDENT}{INDENT}return (TFactory) (object) new Generated{type.Name}(container);"); stringBuilder.AppendLine($"{INDENT}{INDENT}}}"); stringBuilder.AppendLine(); }