WordPress.org

Make WordPress Core

Opened 2 years ago

Closed 2 years ago

#46891 closed defect (bug) (duplicate)

Docs: Add missing description for global wpdb param

Reported by: immeet94 Owned by:
Milestone: Priority: normal
Severity: normal Version:
Component: General Keywords: has-patch needs-refresh
Focuses: docs, coding-standards Cc:

Description

i found that there is missing $wpdb declaration in files.

Attachments (2)

46891.diff (2.1 KB) - added by immeet94 2 years ago.
Please see this file for patch
46891.2.diff (2.2 KB) - added by immeet94 2 years ago.
Update patch and follow coding standards

Download all attachments as: .zip

Change History (7)

@immeet94
2 years ago

Please see this file for patch

#1 @swissspidy
2 years ago

  • Focuses coding-standards removed
  • Milestone changed from Awaiting Review to Future Release
  • Priority changed from normal to low
  • Severity changed from normal to minor
  • Summary changed from Needs documentation improvement. to Docs: Add missing description for global wpdb param
  • Type changed from defect (bug) to enhancement
  • Version trunk deleted

#2 @afercia
2 years ago

  • Keywords needs-refresh added
  • Priority changed from low to normal
  • Severity changed from minor to normal
  • Type changed from enhancement to defect (bug)

Thanks @immeet94 ! Searching through the codebase for @global wpdb, it seems there are more occurrences where wpdb misses a description. Would be great to fix also the other occurrences.

Also, when there are multiple globals (same for params), the type, varname, and descriptions should be aligned with spaces. An example would be:

 * @global wpdb   $wpdb         The WordPress database class.
 * @global string $table_prefix The database table prefix.

Reference to the documentation coding standards: https://make.wordpress.org/core/handbook/best-practices/inline-documentation-standards/php/#docblock-formatting

@immeet94
2 years ago

Update patch and follow coding standards

#3 @immeet94
2 years ago

Hello @afercia

i just update my patch and follow coding standards so please review it.

Thanks Meet

#4 @immeet94
2 years ago

  • Focuses coding-standards added

#5 @SergeyBiryukov
2 years ago

  • Milestone Future Release deleted
  • Resolution set to duplicate
  • Status changed from new to closed

Hi @immeet94, thanks for the patch! We're already tracking this issue in #45604.

Note: See TracTickets for help on using tickets.