[wp-trac] [WordPress Trac] #60480: preg_match() warning in wp_image_add_srcset_and_sizes() when image_meta['file'] is missing
WordPress Trac
noreply at wordpress.org
Thu May 8 14:39:38 UTC 2025
#60480: preg_match() warning in wp_image_add_srcset_and_sizes() when
image_meta['file'] is missing
--------------------------+------------------------------
Reporter: shanemac10 | Owner: (none)
Type: defect (bug) | Status: assigned
Priority: normal | Milestone: Awaiting Review
Component: Import | Version: 6.4.3
Severity: major | Resolution:
Keywords: has-patch | Focuses:
--------------------------+------------------------------
Comment (by enravo):
Although this ticket (#60480) predates my report (#63394), I would like to
note that my ticket provided the actual root-cause analysis and a concrete
fix proposal.
Here is my original report: https://core.trac.wordpress.org/ticket/63394
And PR based on my analysis: https://github.com/Enravo/wordpress-
develop/pull/1
I would greatly appreciate it if this contribution could be acknowledged
in the props for [PR 8772](https://github.com/WordPress/wordpress-
develop/pull/8772).
My patch directly addressed the warning caused by undefined array key
"file" and deprecated preg_match() behavior, which is the same issue fixed
in my PR.
GitHub: @Enravo
--
Ticket URL: <https://core.trac.wordpress.org/ticket/60480#comment:6>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list