#49759 closed defect (bug) (fixed)
Consider un-deprecating 'category_link' and 'tag_link' filters
Reported by: | SergeyBiryukov | Owned by: | whyisjake |
---|---|---|---|
Milestone: | 5.4.1 | Priority: | normal |
Severity: | normal | Version: | |
Component: | Taxonomy | Keywords: | has-patch |
Focuses: | Cc: |
Description (last modified by )
Some history on category_link and tag_link filters:
- [15825] / #12659 turned
get_category_link()
andget_tag_link()
into wrappers forget_term_link()
, and marked the filters as "back compat" in a comment. - [27827] / #27505 marked them as deprecated in favor of
term_link
, though the ticket does not explain why. - [46684] / #48255 used
apply_filters_deprecated()
on them, so developers still using them now get a notice.
I think these filters have the benefit of filtering the category or tag links without having to check the $taxonomy
argument. In hindsight, it seems like they were deprecated by accident rather than an intentional decision.
There are a couple of related filters that are not deprecated:
I don't see a good reason for category_link
and tag_link
to stay deprecated.
Attachments (1)
Change History (14)
This ticket was mentioned in Slack in #core by sergey. View the logs.
5 years ago
This ticket was mentioned in Slack in #core by whyisjake. View the logs.
5 years ago
#8
@
5 years ago
- Owner set to whyisjake
- Resolution set to fixed
- Status changed from new to closed
In 47576:
#12
follow-up:
↓ 13
@
5 years ago
This update made my life hell, how do i downgrade wordpress? I forgot to backup and I trusted that it would not give error.
#13
in reply to:
↑ 12
@
5 years ago
Replying to antonine:
This update made my life hell, how do i downgrade wordpress?
Hi there, I'm sorry to hear you are having issues with WordPress. Please note that this Trac is used for enhancements and bug reporting for the WordPress core software, not for individual support questions.
Please try the support forums to get help with your site: https://wordpress.org/support/forums/.
Hi,
Yes, I got a notice on my blog’s Archive pages using Twenty Twenty and a bunch of plugins…
I agree it’s better to un-deprecate those two filters.