title: ModelMapper - condition AND provider
body: <p>All -</p>
  
  <p>I'm trying to do an "addmapping" with a condition and a provider... bottom line is, one of my values are an Instant, and without the provider, it blows up telling me that Instant doesnt have a default constructor (which it doesnt)</p>
  
  <p>I've gotten this far:</p>
  
  <p>.addMappings(mapper -> {</p>
  
  <pre><code>            mapper.when(ctx -&gt; customerSource(ctx).getEnableDuplicatePOChangedTime().isDirty())
                  .&lt;Instant&gt;map(src -&gt; src.getEnableDuplicatePOChangedTime().getValue(), (dest, v) -&gt; dest.setEnableDuplicatePOChangedTime(v));  
  
              mapper.with(req -&gt; req.getSource()).&lt;Instant&gt;map(src -&gt; src.getEnableDuplicatePOChangedTime().getValue(), (dest, v) -&gt; dest.setEnableDuplicatePOChangedTime(v));
  </code></pre>
  
  <p>})</p>
  
  <p>However, what seems to happen now is, it skips the condition all together - it maps it no matter what!</p>
  
  <p>In debug, this seems to overwrite the condition, setting it to null.</p>
  
  <p>Any thoughts??</p>