+
+
the %2$s site in this installation that you have permissions on.',
- 'Application passwords grant access to
all %2$s sites in this installation that you have permissions on.',
- $blogs_count
- );
+ if ( is_multisite() ) :
+ $blogs = get_blogs_of_user( $user_id, true );
+ $blogs_count = count( $blogs );
+
+ if ( $blogs_count > 1 ) :
+ ?>
+
+ the %2$s site in this installation that you have permissions on.',
+ 'Application passwords grant access to all %2$s sites in this installation that you have permissions on.',
+ $blogs_count
+ );
+
+ if ( is_super_admin( $user_id ) ) {
+ /* translators: 1: URL to my-sites.php, 2: Number of sites the user has. */
+ $message = _n(
+ 'Application passwords grant access to the %2$s site on the network as you have Super Admin rights.',
+ 'Application passwords grant access to all %2$s sites on the network as you have Super Admin rights.',
+ $blogs_count
+ );
+ }
+
+ printf(
+ $message,
+ admin_url( 'my-sites.php' ),
+ number_format_i18n( $blogs_count )
+ );
+ ?>
+
+
- if ( is_super_admin( $user_id ) ) {
- /* translators: 1: URL to my-sites.php, 2: Number of sites the user has. */
- $message = _n(
- 'Application passwords grant access to
the %2$s site on the network as you have Super Admin rights.',
- 'Application passwords grant access to
all %2$s sites on the network as you have Super Admin rights.',
- $blogs_count
+
+
+ 'error',
+ 'additional_classes' => array( 'inline' ),
+ )
);
- }
-
- printf(
- $message,
- admin_url( 'my-sites.php' ),
- number_format_i18n( $blogs_count )
- );
+ endif;
?>
-
-
-
-
-
- 'error',
- 'additional_classes' => array( 'inline' ),
- )
- );
- endif;
- ?>
-
-
- 'application-passwords-user' ) );
- $application_passwords_list_table->prepare_items();
- $application_passwords_list_table->display();
- ?>
-
-
-
-
- set the environment type accordingly to enable application passwords.' ),
- __( 'https://developer.wordpress.org/apis/wp-config-php/#wp-environment-type' )
- );
- ?>
-
-
-
+