Opened 11 years ago
Closed 11 years ago
#33025 closed defect (bug) (fixed)
Invalid argument in class-wp-posts-list-table.php
| Reported by: | newkind | Owned by: | wonderboymusic |
|---|---|---|---|
| Priority: | normal | Milestone: | 4.4 |
| Component: | Posts, Post Types | Version: | 4.2.2 |
| Severity: | normal | Keywords: | has-patch commit |
| Cc: | Focuses: | administration |
Description
HI,
In the file :
wp-admin/includes/class-wp-posts-list-table.php
there's a variable $post_formats set to :
$post_formats = get_theme_support( 'post-formats' );
and right below it there's a loop which causes Warnings when $post_formats doesn't return array
of arguments but boolean :
foreach ( $post_formats[0] as $format ) {
WP should check if $post_formats is array so we wouldn't end up with Invalid Arguments Supplied warning.
Thanks!
Attachments (1)
Change History (3)
Note:
See TracTickets
for help on using tickets.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
33024.diff adds an
is_array()check consistent with other areas in core.