Opened 15 months ago
Closed 13 months ago
#63272 closed enhancement (fixed)
Remove redundant access tags from DocBlocks
| Reported by: | marian1 | Owned by: | SergeyBiryukov |
|---|---|---|---|
| Priority: | normal | Milestone: | 6.9 |
| Component: | General | Version: | |
| Severity: | trivial | Keywords: | has-patch |
| Cc: | Focuses: | docs |
Description
A number of methods include an @access tag in their DocBlocks, even though the visibility is already declared in the function signature. These tags are redundant and add no new information.
I propose removing these tags to reduce redundancy and to align with the WordPress PHP Documentation Standards, which state that @access should be used only in limited circumstances — specifically, when visibility modifiers cannot be used in the code and only when referring to private visibility (e.g., for core-only functions or core classes implementing private APIs).
Change History (4)
This ticket was mentioned in PR #8684 on WordPress/wordpress-develop by @marian1.
15 months ago
#1
- Keywords has-patch added
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
This patch removes
@accesstags from DocBlocks when the visibility is already defined in the method declaration. In such cases, the tags are redundant and do not provide additional value. This change is consistent with the WordPress PHP documentation standards.This patch does not modify affected methods in
WP_User_Search(which is deprecated), or inSimplePie_Decode_HTML_Entities,SimplePie\Parse\Date, andSimplePie\XML\Declaration\Parser.Trac ticket: https://core.trac.wordpress.org/ticket/63272