Opened 6 weeks ago
Closed 5 weeks ago
#65401 closed defect (bug) (fixed)
Docs: Correct replacement links for deprecated contextual help filters
| Reported by: | ekamran | Owned by: | westonruter |
|---|---|---|---|
| Priority: | normal | Milestone: | 7.1 |
| Component: | Administration | Version: | |
| Severity: | normal | Keywords: | has-patch commit |
| Cc: | Focuses: | docs |
Description
The inline documentation for the deprecated contextual_help_list, contextual_help, and default_contextual_help filters uses @see references like:
get_current_screen()->add_help_tab()
get_current_screen()->remove_help_tab()
These are rendered as broken DevHub links because they are method-call chains rather than resolvable function or method references.
The docs should instead reference:
get_current_screen()
WP_Screen::add_help_tab()
WP_Screen::remove_help_tab()
Related Documentation Issue Tracker issue:
https://github.com/WordPress/Documentation-Issue-Tracker/issues/2290
Pull request:
https://github.com/WordPress/wordpress-develop/pull/12071
Change History (7)
This ticket was mentioned in PR #12071 on WordPress/wordpress-develop by @ekamran.
6 weeks ago
#1
#2
@
6 weeks ago
Tested PR: https://github.com/WordPress/wordpress-develop/pull/12071
Environment:
- macOS 26.5.1
- PHP 8.5.5
- WordPress develop checkout
- Tested PR commit: 896ab221ed
- Compared against trunk: 3f1fbe7e8d
Testing performed:
- Applied the PR locally in a clean worktree.
- Confirmed the patch only changes
src/wp-admin/includes/class-wp-screen.php. - Confirmed the change updates the three deprecated contextual help docblocks from method-call
@seereferences likeget_current_screen()->add_help_tab()to valid linkable references:get_current_screen()WP_Screen::add_help_tab()WP_Screen::remove_help_tab()
- Confirmed
WP_Screen::add_help_tab()andWP_Screen::remove_help_tab()exist in the same class. - Confirmed
get_current_screen()exists insrc/wp-admin/includes/screen.php. - Confirmed the runtime replacement strings passed to
apply_filters_deprecated()are unchanged, so this is documentation-only and does not change deprecated filter behavior.
Local checks:
php -l src/wp-admin/includes/class-wp-screen.phppassed.git diff --check origin/trunk...HEAD -- src/wp-admin/includes/class-wp-screen.phppassed.
Result:
The patch works as expected. The updated inline documentation should resolve to the correct Developer Hub references while preserving the existing runtime deprecation messages.
Note:
GitHub Actions currently shows all checks passing on the ticket/PR.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
## Summary
Fixes broken DevHub links for deprecated contextual help filters by replacing method-chain
@seereferences with resolvable function and method references.The updated docs now link to:
get_current_screen()WP_Screen::add_help_tab()WP_Screen::remove_help_tab()Related Documentation Issue Tracker issue: https://github.com/WordPress/Documentation-Issue-Tracker/issues/2290
## Testing
git diff --checkphp -l src/wp-admin/includes/class-wp-screen.php