[wp-trac] [WordPress Trac] #60610: Consider fixing user mistakes and/or adding unit tests for $preferred_ext in wp_mime_type_icon()
WordPress Trac
noreply at wordpress.org
Thu May 30 13:02:02 UTC 2024
#60610: Consider fixing user mistakes and/or adding unit tests for $preferred_ext
in wp_mime_type_icon()
---------------------------------------------+------------------------
Reporter: sabernhardt | Owner: joedolson
Type: enhancement | Status: closed
Priority: normal | Milestone: 6.6
Component: Media | Version: 6.5
Severity: normal | Resolution: fixed
Keywords: has-patch has-unit-tests commit | Focuses:
---------------------------------------------+------------------------
Changes (by joedolson):
* status: accepted => closed
* resolution: => fixed
Comment:
In [changeset:"58248" 58248]:
{{{
#!CommitTicketReference repository="" revision="58248"
Media: Protect mime type icon function from simple errors.
Handle `$preferred_ext` arguments that are passed with minor errors in
formatting, such as incorrect casing or missing `.`. Add unit tests to
verify that an omitted period on an otherwise correct extension is
accepted. Follow up to [57687].
Props sabernhardt, joedolson, khokansardar.
Fixes #60610.
}}}
--
Ticket URL: <https://core.trac.wordpress.org/ticket/60610#comment:7>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list