//Simple function on action
remove_action('some_action', 'some_function');
//Simple function on action with a class
remove_action('some_action', ['class_name', 'some_function']);
Mail
Block email
class fakePhpMailer()
{
publicfunctionsend()
{
returntrue;
}
}
add_action('phpmailer_init', 'blockEmailSending');
functionblockEmailSending(&$phpmailer)
{
$phpmailer = new fakePhpMailer();
}