Pass $this to WP_User::has_cap()'s "user_has_cap" filter
|Reported by:||Viper007Bond||Owned by:||wonderboymusic|
When hooking into the user_has_cap filter to modify the result of a user's capability checks (for example current_user_can()), the filter is not provided access to the user's object. This is important for cases like where WP_User::for_blog() has been called but you only want to modify a user's capabilities for a certain blog.
Change History (5)
comment:2 SergeyBiryukov — 9 months ago
- Keywords 3.7-early added
- Milestone changed from Awaiting Review to Future Release