title: Mapster not mapping
body: <p>I'm using Mapster with DI and I'm trying to map objects that I receive from WS. I was following this guide <a href="https://github.com/MapsterMapper/Mapster/wiki/Dependency-Injection#mapping" rel="nofollow noreferrer">https://github.com/MapsterMapper/Mapster/wiki/Dependency-Injection#mapping</a></p>
  <p>I register TypeAdapterConfig, and ServiceMapper</p>
  <pre><code>var config = new TypeAdapterConfig();
  services.AddSingleton(config);
  services.AddScoped&lt;IMapper, ServiceMapper&gt;();
  </code></pre>
  <p>Blacklist class contains collection of Cards but webservice returns array of long, that I remap to object.</p>
  <pre><code>public class BlacklistMapper : IRegister
  {
      void IRegister.Register(TypeAdapterConfig config)
      {
          config.NewConfig&lt;long, Internal.BlacklistCard&gt;()
              .Map(dest =&gt; dest.Cuid, source =&gt; source);
  
          config.NewConfig&lt;SzWebService.BlackList, Internal.Blacklist&gt;()
              .Map(dest =&gt; dest.Id, source =&gt; source.iBlacklistId)
              .Map(dest =&gt; dest.Crc, source =&gt; source.iBlackListCRC)
              .Map(dest =&gt; dest.Cards, source =&gt; source.lCuid);
      }
  }
  </code></pre>
  <p>Inject mapper in the constuctor</p>
  <pre><code> private readonly IMapper _mapper;
  
   public Service(IMapper mapper)
   {
       _logger = logger;
   }
  </code></pre>
  <p>And finally call it like so</p>
  <pre><code>_mapper.Map&lt;Blacklist&gt;(response.mBlackListData)
  </code></pre>
  <p>The result is always object with default values</p>