Using version 4.
How do I check for null when doing a map? I tried the .Value
, but that's not there on a Null
:
Mapper.CreateMap<Agenda, AgendaViewModel>()
.ForMember(x => x.DateApproved,
y => y.MapFrom(s => DateTime.SpecifyKind(s.DateApproved.Value, DateTimeKind.Utc)));