send_password_change_email
Filters whether to send the password change email.
Usage
add_filter( 'send_password_change_email', 'wp_kama_send_password_change_email_filter', 10, 3 );
/**
* Function for `send_password_change_email` filter-hook.
*
* @param bool $send Whether to send the email.
* @param array $user The original user array.
* @param array $userdata The updated user array.
*
* @return bool
*/
function wp_kama_send_password_change_email_filter( $send, $user, $userdata ){
// filter...
return $send;
}
- $send(true|false)
- Whether to send the email.
- $user(array)
- The original user array.
- $userdata(array)
- The updated user array.
Changelog
| Since 4.3.0 | Introduced. |
Where the hook is called
send_password_change_email
wp-includes/user.php 2725
$send_password_change_email = apply_filters( 'send_password_change_email', true, $user, $userdata );