WordPress.org

Make WordPress Core

Opened 6 years ago

Closed 6 years ago

#21589 closed defect (bug) (fixed)

get_term_feed_link without filter for tag archive

Reported by: andrea.r Owned by: nacin
Milestone: 3.5 Priority: normal
Severity: minor Version: 3.4.1
Component: Feeds Keywords: needs-codex has-patch
Focuses: Cc:

Description

In function get_term_feed_link, located in link-template.php, line 627:

$link = apply_filters( 'category_feed_link', $link, $feed );

should be changed into:

$link = apply_filters( 'tag_feed_link', $link, $feed );

otherwise, it is not possible to edit or inhibit the feed URL in tag archives.

Attachments (1)

21589.patch (571 bytes) - added by SergeyBiryukov 6 years ago.

Download all attachments as: .zip

Change History (5)

#1 @SergeyBiryukov
6 years ago

  • Keywords has-patch added
  • Milestone changed from Awaiting Review to 3.5

Looks like a copy/paste error in [14711].

#2 follow-up: @SergeyBiryukov
6 years ago

A hacky workaround would be to hook into category_feed_link and search for tag/ or tag= in the link (depending on permalink structure).

#3 in reply to: ↑ 2 @andrea.r
6 years ago

Replying to SergeyBiryukov:

A hacky workaround would be to hook into category_feed_link and search for tag/ or tag= in the link (depending on permalink structure).

OK, thank you!!

#4 @nacin
6 years ago

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

In [21662]:

Fix copy-paste error in get_term_feed_link() that caused the category_feed_link filter to run for tags, rather than tag_feed_link. props andrea.r, SergeyBiryukov. fixes #21589.

Note: See TracTickets for help on using tickets.