Warnings filling up logs
-
Heya @jeffpaul
Love the plugin, just a minor request – can you please do a check for the array key before assignment, so that it doesn’t fill logs with warnings?
Here is the code:
wp-content/plugins/simple-page-ordering/class-simple-page-ordering.php:429
:// Get the relevant siblings. if ( 0 === $post->post_parent ) { $siblings = $top_level_pages; } else { $siblings = $children_pages[ $post->post_parent ]; }
Here is my recommended mods:
// Get the relevant siblings. if ( 0 === $post->post_parent ) { $siblings = $top_level_pages; } else { $siblings = !empty($children_pages[ $post->post_parent ])?$children_pages[ $post->post_parent ]:array(); }
Possible, please?
Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
- The topic ‘Warnings filling up logs’ is closed to new replies.