[wp-trac] [WordPress Trac] #33631: Add filter to prevent user creation during site creation
WordPress Trac
noreply at wordpress.org
Mon Aug 31 20:17:49 UTC 2015
#33631: Add filter to prevent user creation during site creation
--------------------------------+------------------------------
Reporter: mackensen | Owner:
Type: enhancement | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Networks and Sites | Version: trunk
Severity: normal | Resolution:
Keywords: | Focuses: multisite
--------------------------------+------------------------------
Changes (by SergeyBiryukov):
* component: Administration => Networks and Sites
Comment:
A workaround:
{{{
function wp33631_check_for_existing_user_during_site_creation() {
if ( ! isset( $_REQUEST['action'] ) || 'add-site' !==
$_REQUEST['action'] ) {
return;
}
if ( ! email_exists( $_POST['blog']['email'] ) ) {
wp_die( 'User does not exist.' );
}
}
add_action( 'admin_init',
'wp33631_check_for_existing_user_during_site_creation' );
}}}
--
Ticket URL: <https://core.trac.wordpress.org/ticket/33631#comment:1>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list