Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions src/wp-admin/includes/class-wp-site-health.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@
* @since 5.2.0
*/


require_once __DIR__ . '/secrets-site-health.php';

#[AllowDynamicProperties]
class WP_Site_Health {
private static $instance = null;
Expand Down
14 changes: 14 additions & 0 deletions src/wp-admin/includes/schema.php
Original file line number Diff line number Diff line change
Expand Up @@ -732,6 +732,7 @@ function populate_roles() {
populate_roles_270();
populate_roles_280();
populate_roles_300();
populate_roles_720();

// Save the updated roles to the database.
if ( $original_use_db ) {
Expand Down Expand Up @@ -968,6 +969,19 @@ function populate_roles_300() {
}
}

/**
* Create and modify WordPress roles for WordPress 7.2.
*
* @since 7.2.0
*/
function populate_roles_720(): void {
$role = get_role( 'administrator' );

if ( ! empty( $role ) ) {
$role->add_cap( 'manage_secrets' );
}
}

if ( ! function_exists( 'install_network' ) ) :
/**
* Install Network.
Expand Down
Loading
Loading