Make WordPress Core

Opened 5 years ago

Closed 5 years ago

#47409 closed enhancement (wontfix)

variable in foreach is used without validation.

Reported by: priyankkpatel's profile priyankkpatel Owned by:
Milestone: Priority: normal
Severity: normal Version: 5.2.1
Component: Widgets Keywords: has-patch
Focuses: administration Cc:

Description

variable in foreach is used without checking whether it is array and not empty.

Attachments (2)

47409.diff (1.8 KB) - added by priyankkpatel 5 years ago.
Patch for wp-admin/widgets.php
47409.patch (1.6 KB) - added by dkarfa 5 years ago.

Download all attachments as: .zip

Change History (3)

@priyankkpatel
5 years ago

Patch for wp-admin/widgets.php

@dkarfa
5 years ago

#1 @SergeyBiryukov
5 years ago

  • Component changed from General to Widgets
  • Focuses administration added
  • Milestone Awaiting Review deleted
  • Resolution set to wontfix
  • Status changed from new to closed

Thanks for the patch! However, $theme_sidebars is defined as an array a few lines above, so there's no need for additional checks here.

Note: See TracTickets for help on using tickets.