[wp-trac] [WordPress Trac] #46338: taxonomy_meta_box_sanitize_cb_checkboxes: Warning: array_map(): Expected parameter 2 to be an array, string given
WordPress Trac
noreply at wordpress.org
Tue Apr 16 06:03:46 UTC 2024
#46338: taxonomy_meta_box_sanitize_cb_checkboxes: Warning: array_map(): Expected
parameter 2 to be an array, string given
--------------------------+------------------------------
Reporter: conner_bw | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Taxonomy | Version: 5.1
Severity: normal | Resolution:
Keywords: | Focuses:
--------------------------+------------------------------
Comment (by oglekler):
According to this:
https://developer.wordpress.org/reference/functions/register_taxonomy/
'meta_box_cb' can have a callback function name and be equal to
'post_categories_meta_box' for hierarchical taxonomies and
'post_tags_meta_box' for non-hierarchical taxonomies. This was my mistake;
I didn't check the documentation properly, and taxonomy is not
hierarchical by default. On the other hand, this situation with settings
that are not compatible with each other can possibly be handled without
fatal error.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/46338#comment:3>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list