[wp-trac] [WordPress Trac] #27194: wp.editPost does not allow removal of all terms for a taxonomy
WordPress Trac
noreply at wordpress.org
Mon Feb 24 03:42:58 UTC 2014
#27194: wp.editPost does not allow removal of all terms for a taxonomy
--------------------------+-----------------------------
Reporter: maxcutler | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: XML-RPC | Version: 3.8.1
Severity: normal | Keywords:
Focuses: |
--------------------------+-----------------------------
`wp.newPost` and `wp.editPost` XML-RPC methods have a `terms` argument
which allows setting of the terms associated with the post. This argument
is an array with taxonomy names as keys and arrays of term IDs as values.
If a taxonomy is explicitly supplied with an empty list of IDs, the
expectation is that this would cause removal of all currently-associated
terms in that taxonomy from the post.
For example, if a post has 'Cat A' and 'Cat B' associated with it, passing
`array( 'category' => array() )` should cause both of those categories to
be unassociated with the post.
This issue has existed since I wrote this code back in 3.4.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/27194>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list