You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Hooks/Docs: Missing PHPDoc on deprecated hooks and legacy load-*.php actions in wp-admin (9 hooks) #27
These are legacy aliases for the dynamic load-{$page} hook. Each needs a /** This action is documented in wp-admin/admin.php */ cross-reference pointing to the primary load-{$pagenow} hook, or a minimal PHPDoc of its own if Weston prefers.
Fix approach
deprecated.php hooks: add @since, @deprecated X.X.0, and @param PHPDoc blocks.
admin.php legacy load hooks: add cross-reference comments pointing to the primary load-{$pagenow} PHPDoc in the same file.
Checked all hooks from this issue for multiple call sites:
Legacy load-*.php hooks (5 in admin.php):
load-page-new.php, load-page.php, load-categories.php, load-edit-link-categories.php, load-edit-tags.php — single occurrence each. These are legacy aliases for the dynamic load-{$pagenow} hook. Best approach: add /** This action is documented in wp-admin/admin.php */ xref pointing to the primary load-{$pagenow} PHPDoc earlier in the same file.
Deprecated hooks (4 in wp-admin/includes/deprecated.php):
get_editable_authors, get_others_drafts, wp_create_thumbnail, pre_user_search — single occurrence each, no modern equivalent. Need own PHPDoc with @since, @deprecated, @param.
The 5 legacy load-*.php hooks in wp-admin/admin.php are fixed in PR WordPress#11205 (tracked separately as #37).
Remaining (4 hooks): The deprecated hooks in wp-admin/includes/deprecated.php still need their own PHPDoc blocks with @since, @deprecated, and @param tags:
Won't fix — deprecated hooks with no active use. The 5 legacy load-*.php hooks were fixed in PR WordPress#11205. The 4 remaining deprecated hooks in wp-admin/includes/deprecated.php would add review noise without practical value.
Activity
apermo commentedon Mar 8, 2026
Cross-reference analysis
Checked all hooks from this issue for multiple call sites:
Legacy load-*.php hooks (5 in admin.php):
load-page-new.php,load-page.php,load-categories.php,load-edit-link-categories.php,load-edit-tags.php— single occurrence each. These are legacy aliases for the dynamicload-{$pagenow}hook. Best approach: add/** This action is documented in wp-admin/admin.php */xref pointing to the primaryload-{$pagenow}PHPDoc earlier in the same file.Deprecated hooks (4 in wp-admin/includes/deprecated.php):
get_editable_authors,get_others_drafts,wp_create_thumbnail,pre_user_search— single occurrence each, no modern equivalent. Need own PHPDoc with@since,@deprecated,@param.apermo commentedon Mar 8, 2026
Partial fix
The 5 legacy
load-*.phphooks inwp-admin/admin.phpare fixed in PR WordPress#11205 (tracked separately as #37).Remaining (4 hooks): The deprecated hooks in
wp-admin/includes/deprecated.phpstill need their own PHPDoc blocks with@since,@deprecated, and@paramtags:get_editable_authors(line 270)get_others_drafts(line 715)pre_user_search(line 560)wp_create_thumbnail(line 1137)apermo commentedon Mar 8, 2026
Won't fix — deprecated hooks with no active use. The 5 legacy load-*.php hooks were fixed in PR WordPress#11205. The 4 remaining deprecated hooks in wp-admin/includes/deprecated.php would add review noise without practical value.