Opened 12 years ago
Closed 12 years ago
#24490 closed enhancement (fixed)
Pass $this to WP_User::has_cap()'s "user_has_cap" filter
Reported by: |
|
Owned by: |
|
---|---|---|---|
Milestone: | 3.7 | Priority: | normal |
Severity: | normal | Version: | 3.5.1 |
Component: | Role/Capability | Keywords: | has-patch 3.7-early |
Focuses: | Cc: |
Description
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.
Attachments (1)
Change History (5)
Note: See
TracTickets for help on using
tickets.
these are all marked 3.7-early