Skip to content

Instantly share code, notes, and snippets.

@maiconheck
Last active June 20, 2023 12:34
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save maiconheck/824f26a683b943a511d8431e2038b22b to your computer and use it in GitHub Desktop.
Save maiconheck/824f26a683b943a511d8431e2038b22b to your computer and use it in GitHub Desktop.
[2º improvement] An anemic entity sample for blog posting.
public class Lead
{
// Initializing Segments to avoid an exception.
public Lead(string name, string email)
{
Name = name;
Email = email;
_segments = new List<Segment>();
}
public string Email { get; set; }
// ... remaining code omitted for simplicity ...
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment