WordPress.org

Make WordPress Core

Opened 5 years ago

Closed 5 years ago

#9436 closed defect (bug) (fixed)

'the_tags' filter not applied on the_tags() function

Reported by: scribu Owned by:
Milestone: 2.8 Priority: normal
Severity: normal Version: 2.5
Component: Taxonomy Keywords: has-patch
Focuses: Cc:

Description

When you call the_tags() this is what happens:

the_tags() => the_terms() => get_the_term_list() => apply_filters( "term_links-$taxonomy")

But 'the_tags' filter is called in get_tags_list().

This is how it should be:

the_tags() => get_tags_list()

Attachments (1)

the_tags.patch (751 bytes) - added by scribu 5 years ago.
Also pass the arguments to the filter

Download all attachments as: .zip

Change History (8)

comment:1 scribu5 years ago

  • Cc scribu@… added

scribu5 years ago

Also pass the arguments to the filter

comment:2 scribu5 years ago

  • Component changed from General to Taxonomy
  • Owner changed from anonymous to ryan

comment:3 scribu5 years ago

  • Owner ryan deleted

comment:4 jbsil5 years ago

+1 But I believe this goes back as far as 2.5, maybe further.

comment:5 scribu5 years ago

  • Version changed from 2.8 to 2.5

You're right. All the more reason to fix it. :)

comment:6 jbsil5 years ago

I came up with an almost identical fix to the patch scribu posted before I knew this ticket existed. I've tested his patch on 2.5.1 and 2.8-svn, but nothing in between. Can someone qualified tag this as (tested|needs-testing|commit)?

comment:7 ryan5 years ago

  • Resolution set to fixed
  • Status changed from new to closed

(In [10888]) Invoke the_tags filter in the_tags(). Props scribu. fixes #9436

Note: See TracTickets for help on using tickets.