Skip to content

When webp_uploads_prefer_smaller_image_file is set to true, an undefine error occurs #396

@mukeshpanchal27

Description

@mukeshpanchal27

Bug Description

It generate undefine variable error when webp_uploads_prefer_smaller_image_file is set to true.
#7 (comment)

Steps to reproduce

  1. Add add_filter( 'webp_uploads_prefer_smaller_image_file', '__return_true' ); in theme or plugin
  2. Upload image from this comment
  3. See error

Error Message

Notice: Undefined variable: size_data in /var/www/html/wp-content/plugins/performance/modules/images/webp-uploads/load.php on line 484

Additional Context

  • PHP Version: 7.4.30
  • OS: Windows 10
  • Browser: Chrome
  • Plugin Version: 1.2.0
  • Device: Desktop

Metadata

Metadata

Labels

[Plugin] Modern Image FormatsIssues for the Modern Image Formats plugin (formerly WebP Uploads)[Type] BugAn existing feature is broken

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions