diff --git a/DD.Persistence.Repository/DependencyInjection.cs b/DD.Persistence.Repository/DependencyInjection.cs index 3e60e1e..f960b7c 100644 --- a/DD.Persistence.Repository/DependencyInjection.cs +++ b/DD.Persistence.Repository/DependencyInjection.cs @@ -11,6 +11,10 @@ public static class DependencyInjection { public static void MapsterSetup() { + TypeAdapterConfig.GlobalSettings.Default.Config + .ForType() + .Ignore(dest => dest.System, dest => dest.SystemId); + TypeAdapterConfig.GlobalSettings.Default.Config .ForType() .Map(dest => dest.Value, src => new DataWithWellDepthAndSectionDto() @@ -21,11 +25,6 @@ public static class DependencyInjection Value = src.Value, Id = src.Id }); - - TypeAdapterConfig.GlobalSettings.Default.Config - .ForType() - .Ignore(dest => dest.System, dest => dest.SystemId); - } public static IServiceCollection AddInfrastructure(this IServiceCollection services)