public static FriendshipApiModel From(Friendship friendship)
 {
     return(new FriendshipApiModel
     {
         FromId = friendship.FromId,
         ToId = friendship.ToId,
         To = UserProfileApiModel.From(friendship.To),
     });
 }
Ejemplo n.º 2
0
 public static UserProfile To(this UserProfileApiModel model)
 {
     return(new UserProfile
     {
         Id = model.Id,
         BirthDate = model.BirthDate,
         FirstName = model.FirstName,
         LastName = model.LastName,
         Sex = model.Sex
     });
 }