File tree Expand file tree Collapse file tree 1 file changed +8
-9
lines changed
src/wp-includes/rest-api/endpoints Expand file tree Collapse file tree 1 file changed +8
-9
lines changed Original file line number Diff line number Diff line change @@ -654,17 +654,16 @@ public function create_item( $request ) {
654654 *
655655 * @since 6.9.0
656656 *
657- * @param string $notify Determines who gets notified. Accepts:
658- * - 'admin' (default) or an empty string: Notify only the site administrator.
659- * - 'user': Notify only the new user.
660- * - 'both': Notify both admin and user.
661- * - ' false' : Disable notifications entirely.
662- * @param int $user_id User ID.
657+ * @param string|bool $notify Determines who gets notified. Accepts:
658+ * - 'admin' or an empty string: Notify only the site administrator.
659+ * - 'user': Notify only the new user.
660+ * - 'both': Notify both admin and user.
661+ * - false: Disable notifications entirely.
662+ * @param int $user_id User ID.
663663 */
664664 $ notify = apply_filters ( 'rest_wp_user_created_notification ' , 'both ' , $ user_id );
665- if ( $ notify && 'false ' !== $ notify ) {
666- wp_new_user_notification ( $ user_id , null , $ notify );
667- }
665+
666+ wp_new_user_notification ( $ user_id , null , $ notify );
668667
669668 $ user = get_user_by ( 'id ' , $ user_id );
670669
You can’t perform that action at this time.
0 commit comments