#20917 closed defect (bug) (fixed)
Illegal offset type in empty() when editing a draft post by another user
| Reported by: | duck_ | Owned by: | ryan |
|---|---|---|---|
| Priority: | normal | Milestone: | 3.4 |
| Component: | Warnings/Notices | Version: | 3.4 |
| Severity: | major | Keywords: | has-patch commit |
| Cc: | Focuses: |
Description (last modified by )
Warning: Illegal offset type in isset or empty in wp-includes/capabilities.php on line 885
Triggered by a call to current_user_can() when building the View Post button for the tool bar.
current_user_can( 'read_post', $post_id ) will return an array containing arrays since [21046] for draft posts created by other users because map_meta_cap() returns an array and its result is being put in an array.
Attachments (1)
Change History (5)
Note:
See TracTickets
for help on using tickets.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
Looks good.