Skip to content

Instantly share code, notes, and snippets.

@danielbitzer
Last active September 14, 2022 11:18
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save danielbitzer/7000bd17a72060df3f0d60d0762a71c0 to your computer and use it in GitHub Desktop.
Save danielbitzer/7000bd17a72060df3f0d60d0762a71c0 to your computer and use it in GitHub Desktop.
AutomateWoo - Blacklist an email address or multiple emails based on domain
<?php
// this filter was added in AW 3.6.0
add_filter( 'automatewoo/mailer/blacklist', function( $blacklist ){
$blacklist[] = 'email@example.com'; // block a single email
$blacklist[] = '@hotmail.com'; // block all emails from a domain
return $blacklist;
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment