Make WordPress Core

Opened 3 years ago

Closed 3 years ago

#54856 closed defect (bug) (fixed)

Use a more appropriate variable name in link_advanced_meta_box()

Reported by: sergeybiryukov's profile SergeyBiryukov Owned by: sergeybiryukov's profile SergeyBiryukov
Milestone: 6.0 Priority: normal
Severity: normal Version:
Component: General Keywords: good-first-bug has-patch
Focuses: coding-standards Cc:

Description

Background: #45059.

In [45667], the $r variable in link_advanced_meta_box() was renamed to $parsed_args, along with other instances used with wp_parse_args().

In hindsight, this particular instance was unrelated to the other changes, as it's not used with wp_parse_args(). So the correct variable name to use here would be $rating, which I think $r was a short for.

Attachments (1)

54856.diff (995 bytes) - added by mkox 3 years ago.
Rename $parsed_args to $rating in link_advanced_meta_box

Download all attachments as: .zip

Change History (4)

@mkox
3 years ago

Rename $parsed_args to $rating in link_advanced_meta_box

#1 @mkox
3 years ago

  • Keywords has-patch added; needs-patch removed

#2 @SergeyBiryukov
3 years ago

The patch looks perfect, thanks!

#3 @SergeyBiryukov
3 years ago

  • Owner set to SergeyBiryukov
  • Resolution set to fixed
  • Status changed from new to closed

In 52620:

Coding Standards: Use a more appropriate variable name in link_advanced_meta_box().

Follow-up to [45667].

Props mkox, SergeyBiryukov.
Fixes #54856.

Note: See TracTickets for help on using tickets.