WordPress.org

Make WordPress Core

Opened 17 months ago

Closed 4 months ago

#35147 closed defect (bug) (fixed)

unregister_sidebar function of the comment document

Reported by: tmatsuur Owned by: Soean
Milestone: 4.8 Priority: normal
Severity: normal Version: 4.4
Component: Widgets Keywords: good-first-bug has-patch
Focuses: Cc:

Description

Parameter of 'is_registered_sidebar' functions that have been added in version 4.4 has become a string or int.

In contrast to this, the parameter of the 'unregister_sidebar' function has become a string.

Both parameters is the key of the $wp_registered_sidebars. I think it is better to be unified.

Attachments (1)

35147.diff (701 bytes) - added by Soean 16 months ago.

Download all attachments as: .zip

Change History (8)

#2 in reply to: ↑ 1 @tmatsuur
16 months ago

Replying to welcher:
Thank you.

#4 @welcher
16 months ago

  • Keywords has-patch dev-feedback added

#5 @welcher
16 months ago

  • Keywords good-first-bug needs-patch added; has-patch dev-feedback removed

@Soean
16 months ago

#6 @Soean
16 months ago

  • Keywords has-patch added; needs-patch removed

I copied the parameter and comment from 'is_registered_sidebar' to 'unregister_sidebar'. So that it's now unified.
See: 35147.diff

Last edited 16 months ago by Soean (previous) (diff)

#7 @DrewAPicture
11 months ago

  • Owner set to Soean
  • Status changed from new to assigned

Assigning to mark the good-first-bug as "claimed".

See 35147.diff

#8 @SergeyBiryukov
4 months ago

  • Milestone changed from Awaiting Review to 4.8

#9 @SergeyBiryukov
4 months ago

  • Resolution set to fixed
  • Status changed from assigned to closed

In 39892:

Widgets: In unregister_sidebar(), rename the $name parameter to $sidebar_id for consistency with is_registered_sidebar().

Also correct the parameter type in @param entry.

Props Soean, tmatsuur.
Fixes #35147.

Note: See TracTickets for help on using tickets.