[wp-trac] [WordPress Trac] #38306: WP_REST_Request->get_params strips numeric keys
WordPress Trac
noreply at wordpress.org
Wed Nov 2 04:31:39 UTC 2016
#38306: WP_REST_Request->get_params strips numeric keys
--------------------------------------+-----------------------
Reporter: sswells | Owner: joehoyle
Type: defect (bug) | Status: assigned
Priority: normal | Milestone: 4.7
Component: REST API | Version: 4.4
Severity: normal | Resolution:
Keywords: has-patch has-unit-tests | Focuses:
--------------------------------------+-----------------------
Changes (by joehoyle):
* keywords: => has-patch has-unit-tests
Comment:
`array_merge` and the + operator are both issues, as even the `+` will
make numeric keys integers after it's done. It seems the easiest and best
way is to manually implement a foreach. Added unit test also.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/38306#comment:9>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list