Opened 3 years ago
Last modified 4 months ago
#57619 new enhancement
register_taxonomy doesn't check for reserved terms
| Reported by: |
|
Owned by: | |
|---|---|---|---|
| Milestone: | Awaiting Review | Priority: | normal |
| Severity: | normal | Version: | |
| Component: | Taxonomy | Keywords: | 2nd-opinion |
| Focuses: | coding-standards | Cc: |
Description
Implement a check in register_taxonomy for reserved terms.
Attachments (1)
Note: See
TracTickets for help on using
tickets.
I had a list of 13 taxonomies to register for certain CPT. Of course, I knew about reserved terms, but It didn't occur to me to check and as the result I registered "themes" taxonomy. It worked fine, but I got a side effect that was difficult to discover as editors were using Thumbnail block to add Thumbnail and no one was complaining that "Set featured image" button is gone.
I think _doing_it_wrong() will be very useful to notify that word is reserved and cannot be used as taxonomy.