Skip to content

Instantly share code, notes, and snippets.

@BurlesonBrad
Created August 30, 2015 02:37
Show Gist options
  • Save BurlesonBrad/d43c283fb594d82c7902 to your computer and use it in GitHub Desktop.
Save BurlesonBrad/d43c283fb594d82c7902 to your computer and use it in GitHub Desktop.
Two Emails for Low Stock
<?php
function woo_extra_email_recipient($recipient, $object) {
$recipient = $recipient . ', [email protected]';
return $recipient;
}
add_filter( 'woocommerce_low_stock', 'woo_extra_email_recipient', 10, 2);
@BurlesonBrad
Copy link
Author

function woo_extra_email_recipient($recipient, $object) {
    $recipient = $recipient . ', [email protected]';
    return $recipient;
}
add_filter( 'woocommerce_no_stock', 'woo_extra_email_recipient', 10, 2);
Now, what's the correct php code when Amit wants to use both woocommerce_no_stock and woocommerce_low_stock

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment