wp_maybe_grant_site_health_caps
wp_maybe_grant_site_health_caps ( $allcaps, $caps, $args, $user )
Parameters:- (bool[]) allcaps An array of all the user's capabilities.
- (string[]) caps Required primitive capabilities for the requested capability.
- (array) args { Arguments that accompany the requested capability check. @type string $0 Requested capability. @type int $1 Concerned user ID. @type mixed ...$2 Optional second and further parameters, typically object ID. }
- (WP_User) user The user object.
Returns:- (bool[]) Filtered array of the user's capabilities.
Defined at: - Introduced in WordPress: 5.2.2
- Deprecated in WordPress: —
Description
Filters the user capabilities to grant the 'view_site_health_checks' capabilities as necessary.