[wp-trac] [WordPress Trac] #65345: Site Icon subsizes use wrong array key 'width ' instead of 'width'
WordPress Trac
noreply at wordpress.org
Thu Jun 4 09:50:33 UTC 2026
#65345: Site Icon subsizes use wrong array key 'width ' instead of 'width'
----------------------------------------------------+---------------------
Reporter: tomatillo | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: 7.1
Component: Media | Version: 4.3
Severity: normal | Resolution:
Keywords: has-patch needs-testing has-unit-tests | Focuses:
----------------------------------------------------+---------------------
Comment (by pedrofigueroa1989):
== Test Report
Patch tested: https://github.com/WordPress/wordpress-develop/pull/11975
=== Environment
- WordPress: 7.0
- Subdirectory: No
- PHP: 8.3.31
- Server: Apache/2.4.67 (Debian)
- Database: mysqli (Server: 12.3.2-MariaDB-ubu2404 / Client: mysqlnd
8.3.31)
- Browser: Firefox 151.0
- OS: Ubuntu
- Theme: Twenty Twenty-Five 1.5
- MU Plugins: None activated
- Plugins:
* Test Reports 1.3.0
=== Steps taken
1. A local WordPress dev environment was set up.
2. A non-square image was uploaded via Media → Add New.
3. The image was set as the site icon without cropping: {{{wp option
update site_icon <attachment_id>}}}
4. The attachment metadata was regenerated with the site icon filters
enabled
5. The generated subsizes were inspected: {{{wp post meta get
<attachment_id> _wp_attachment_metadata}}}
6. site_icon-270, site_icon-192, site_icon-180, and site_icon-32 are NOT
square crops.
7. ❌ Patch is failing
=== Expected result
- I expected site_icon-270, site_icon-192, site_icon-180, and site_icon-32
to be square crops of the original image.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/65345#comment:7>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list