W3cubDocs

/WordPress

apply_filters( 'map_meta_cap', string[] $caps, string $cap, int $user_id, array $args )

Filters a user’s capabilities depending on specific context and/or privilege.

Parameters

$caps

(string[]) Array of the user's capabilities.

$cap

(string) Capability name.

$user_id

(int) The user ID.

$args

(array) Adds the context to the cap. Typically the object ID.

Source

File: wp-includes/capabilities.php

View on Trac

Changelog

Version Description
2.8.0 Introduced.

© 2003–2019 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/hooks/map_meta_cap