Make WordPress Core

Opened 9 months ago

Closed 8 months ago

Last modified 8 months ago

#60643 closed defect (bug) (fixed)

use strict compare in GD image save function

Reported by: pbearne's profile pbearne Owned by: pbearne's profile pbearne
Milestone: 6.6 Priority: normal
Severity: normal Version:
Component: Media Keywords: has-patch
Focuses: Cc:

Description


Change History (4)

This ticket was mentioned in PR #6187 on WordPress/wordpress-develop by @pbearne.


9 months ago
#1

  • Keywords has-patch added

…ided diffs, here is the appropriate commit message:

Change comparison operator to strict in mime_type checks

The operator in the mime_type checks has been switched from '==' to '===' for 'image/webp' and 'image/avif' in the class-wp-image-editor-gd.php file. This change ensures a stricter comparison, improving code reliability and reducing potential bugs.

Trac ticket: 60643

#2 @SergeyBiryukov
8 months ago

  • Milestone changed from Awaiting Review to 6.6

#3 @SergeyBiryukov
8 months ago

  • Resolution set to fixed
  • Status changed from assigned to closed

In 57811:

Coding Standards: Use strict comparison in WP_Image_Editor_GD::_save().

Follow-up to [50810], [57524].

Props pbearne, mukesh27.
Fixes #60643.

@SergeyBiryukov commented on PR #6187:


8 months ago
#4

Thanks for the PR! Merged in r57811.

Note: See TracTickets for help on using tickets.