-
Notifications
You must be signed in to change notification settings - Fork 28
Closed
Labels
Description
Consider following classes:
class PaperModel
{
public int Id { get; set; }
public int? PaperId { get; set; }
public Paper Paper { get; set; }
}
class RockModel
{
public int Id { get; set; }
public int? RockId { get; set; }
public Rock Rock { get; set; }
}
class Rock
{
public int Id { get; set; }
}
class Paper
{
public int Id { get; set; }
}
Now if we try to do the following:
var paperModel = new PaperModel();
var rockModel = new RockModel();
Mapper.Map(rockModel).Over(paperModel);
The property "Paper" of variable "paperModel" gets initialized when it is expected to be null.
This issue is similar to #21 however in this case both source and destination have missing target members.