PHP error if there are no additional image sizes
-
Hi Tobias,
PHP throws an error (actually 2) when I add the Available Sizes column to Media page AND there are no additional image sizes.
I edited the classes/column/media/available-sizes.php file on line 53 to also check if
$_wp_additional_image_sizesis not empty and it seems to be solved:if ( ! empty( $_wp_additional_image_sizes ) && $missing = array_diff( array_keys( $_wp_additional_image_sizes), array_keys( $meta['sizes'] ) ) ) {A couple of minutes before I was using some additional image sizes and everything was working fine.
I’d appreciate if you add this solution (or a better one if you have it, of course) to next versions.
Thanks for the plugin!
The topic ‘PHP error if there are no additional image sizes’ is closed to new replies.