Networks and Sites: Simplify the check for main site on Network Admin → Sites screen.
This replaces a site ID comparison when displaying action links in `WP_MS_Sites_List_Table::handle_row_actions()` with a dedicated function call, `is_main_site()`, for clarity. Follow-up to [13918], [25125], [26120], [32644], [38814]. Props ecorica, spacedmonkey, SergeyBiryukov. Fixes #58150. Built from https://develop.svn.wordpress.org/trunk@55666 git-svn-id: http://core.svn.wordpress.org/trunk@55178 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
150781cb41
commit
19d36bfdd2
|
@ -732,7 +732,7 @@ class WP_MS_Sites_List_Table extends WP_List_Table {
|
||||||
__( 'Dashboard' )
|
__( 'Dashboard' )
|
||||||
);
|
);
|
||||||
|
|
||||||
if ( get_network()->site_id !== (int) $blog['blog_id'] ) {
|
if ( ! is_main_site( $blog['blog_id'] ) ) {
|
||||||
if ( '1' === $blog['deleted'] ) {
|
if ( '1' === $blog['deleted'] ) {
|
||||||
$actions['activate'] = sprintf(
|
$actions['activate'] = sprintf(
|
||||||
'<a href="%1$s">%2$s</a>',
|
'<a href="%1$s">%2$s</a>',
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
*
|
*
|
||||||
* @global string $wp_version
|
* @global string $wp_version
|
||||||
*/
|
*/
|
||||||
$wp_version = '6.3-alpha-55665';
|
$wp_version = '6.3-alpha-55666';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||||
|
|
Loading…
Reference in New Issue