Multisite: Require a site title when a site is created

The UI for adding a site says that title is required, however the actual code wasn't requiring it.

Props ideag.
Fixes #54012.

Built from https://develop.svn.wordpress.org/trunk@55894


git-svn-id: http://core.svn.wordpress.org/trunk@55406 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Aaron Jorbin 2023-06-08 09:07:20 +00:00
parent 759544181d
commit 1031b96997
2 changed files with 5 additions and 1 deletions

View File

@ -83,6 +83,10 @@ if ( isset( $_REQUEST['action'] ) && 'add-site' === $_REQUEST['action'] ) {
}
}
if ( empty( $title ) ) {
wp_die( __( 'Missing site title.' ) );
}
if ( empty( $domain ) ) {
wp_die( __( 'Missing or invalid site address.' ) );
}

View File

@ -16,7 +16,7 @@
*
* @global string $wp_version
*/
$wp_version = '6.3-alpha-55893';
$wp_version = '6.3-alpha-55894';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.