Changeset 53698 for trunk/src/wp-includes/pluggable.php
- Timestamp:
- 07/12/2022 09:03:39 PM (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/pluggable.php
r53483 r53698 2111 2111 $blogname = wp_specialchars_decode( get_option( 'blogname' ), ENT_QUOTES ); 2112 2112 2113 if ( 'user' !== $notify ) { 2113 /** 2114 * Filters whether the admin is notified of a new user registration. 2115 * 2116 * @since 6.1.0 2117 * 2118 * @param bool $send Whether to send the email. Default true. 2119 * @param WP_User $user User object for new user. 2120 */ 2121 $send_notification_to_admin = apply_filters( 'wp_send_new_user_notification_to_admin', true, $user ); 2122 2123 if ( 'user' !== $notify && true === $send_notification_to_admin ) { 2114 2124 $switched_locale = switch_to_locale( get_locale() ); 2115 2125 … … 2159 2169 } 2160 2170 2171 /** 2172 * Filters whether the user is notified of their new user registration. 2173 * 2174 * @since 6.1.0 2175 * 2176 * @param bool $send Whether to send the email. Default true. 2177 * @param WP_User $user User object for new user. 2178 */ 2179 $send_notification_to_user = apply_filters( 'wp_send_new_user_notification_to_user', true, $user ); 2180 2161 2181 // `$deprecated` was pre-4.3 `$plaintext_pass`. An empty `$plaintext_pass` didn't sent a user notification. 2162 if ( 'admin' === $notify || ( empty( $deprecated ) && empty( $notify ) ) ) {2182 if ( 'admin' === $notify || true !== $send_notification_to_user || ( empty( $deprecated ) && empty( $notify ) ) ) { 2163 2183 return; 2164 2184 }
Note: See TracChangeset
for help on using the changeset viewer.