Trying to access array offset on value of type bool
-
I got a lot of these warnings in debug.log
PHP Warning: Trying to access array offset on value of type bool in \wp-content\plugins\wp-performance-pack\modules\dynamic_images\class.wppp_serve_image.php on line 211
In line 207 of said page, function
image_resize_dimensions
can return false instead of array, so an extra check for$new_size
is required next line:if ( $new_size && ( abs( $new_size[ 4 ] - $this->width ) <= 1 ) && ( abs( $new_size[ 5 ] - $this->height ) <= 1 ) ) {
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘Trying to access array offset on value of type bool’ is closed to new replies.