mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-02-28 19:52:53 +00:00
In WP_Posts_List_Table::inline_edit(), check that $post_formats[0] is an array before traversing.
Props DrewAPicture. Fixes #33025. git-svn-id: https://develop.svn.wordpress.org/trunk@33667 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
98de66207f
commit
695560bf58
@ -1473,13 +1473,13 @@ class WP_Posts_List_Table extends WP_List_Table {
|
||||
<option value="-1"><?php _e( '— No Change —' ); ?></option>
|
||||
<option value="0"><?php echo get_post_format_string( 'standard' ); ?></option>
|
||||
<?php
|
||||
|
||||
foreach ( $post_formats[0] as $format ) {
|
||||
?>
|
||||
<option value="<?php echo esc_attr( $format ); ?>"><?php echo esc_html( get_post_format_string( $format ) ); ?></option>
|
||||
<?php
|
||||
if ( is_array( $post_formats[0] ) ) {
|
||||
foreach ( $post_formats[0] as $format ) {
|
||||
?>
|
||||
<option value="<?php echo esc_attr( $format ); ?>"><?php echo esc_html( get_post_format_string( $format ) ); ?></option>
|
||||
<?php
|
||||
}
|
||||
}
|
||||
|
||||
?>
|
||||
</select></label>
|
||||
<?php
|
||||
|
||||
Loading…
Reference in New Issue
Block a user