Skip to content

Instantly share code, notes, and snippets.

@davidelettieri
Last active April 3, 2020 18:17
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 davidelettieri/3bdbb6315d3a9e08a585a74974a2b712 to your computer and use it in GitHub Desktop.
Save davidelettieri/3bdbb6315d3a9e08a585a74974a2b712 to your computer and use it in GitHub Desktop.
bool ValidateEmail(Customer c) { /**/ }
bool ValidateNameSurname(Customer c) { /**/ }
bool SendEmail(Customer c) { /**/ }
bool SendEmailToCustomerIfValid(Customer c) {
if(!ValidateNameSurname(c))
return false;
if(!ValidateEmail(c))
return false;
return SendEmail(c);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment