/// <summary> /// Maps the guests. /// </summary> /// <param name="guest">The guest.</param> /// <param name="personMessages">The messages.</param> /// <param name="messageTypeList">The message Type Master List.</param> internal static void MapGuests(Guest guest, ListResult<DataAccess.Entities.PersonMessage> personMessages, ListResult<DataAccess.Entities.MessageType> messageTypeList) { var messageCollection = MessageMapper.MapCollection(personMessages.Items, guest.GuestId, messageTypeList); if (messageCollection != null && messageCollection.Count > 0) { guest.HasMessage = true; guest.AssignMessages(messageCollection); } }