#57594 closed defect (bug) (fixed)
Correct type in rss_widget_feed_link filter docs
| Reported by: | sabernhardt | Owned by: | joedolson |
|---|---|---|---|
| Priority: | normal | Milestone: | 6.2 |
| Component: | Widgets | Version: | |
| Severity: | minor | Keywords: | needs-dev-note |
| Cc: | Focuses: | docs |
Description
In changeset:52031, the rss_widget_feed_link filter's DocBlock says the first parameter is a string. However, I had recommended returning false to remove the link.
Mentioning both possibilities is probably enough, though I think switching to __return_empty_string would improve it (in the documentation and in Twenty Twenty-One).
Attachments (1)
Change History (9)
#3
@
4 years ago
- Milestone Awaiting Review → 6.2
- Owner set to
- Status new → reviewing
It certainly cleans things up. It's a minor tweak, so I don't see any reason not to get it into 6.2. I can take that.
This ticket was mentioned in PR #4117 on WordPress/wordpress-develop by @joedolson.
4 years ago
#5
Trac ticket: https://core.trac.wordpress.org/ticket/57594
@joedolson commented on PR #4117:
4 years ago
#6
#7
@
4 years ago
- Keywords commit removed
- Resolution → fixed
- Status reviewing → closed
Fixed in [55409]
#8
@
3 years ago
- Keywords needs-dev-note added; has-patch removed
The dev note from WP5.9 probably could be updated. Here's a draft for the modified example and revision note:
add_filter( 'rss_widget_feed_link', '__return_empty_string' );
For Twenty Twenty-One, the
after_setup_themeaction contains the filter. Update: Since March 2023, Twenty Twenty-One's filter returns an empty string instead of the booleanfalse. See #57594.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
editing documentation and Twenty Twenty-One