Make WordPress Core

Opened 20 years ago

Closed 20 years ago

Last modified 20 years ago

#2313 closed defect (bug) (fixed)

classes.php : missing test before a foreach

Reported by: ozh's profile Ozh Owned by: ryan's profile ryan
Milestone: Priority: normal
Severity: trivial Version: 2.0
Component: General Keywords: foreach warning classes pages bg|has-patch
Focuses: Cc:

Description

line 372 of wp-includes/classes.php we have "$all_page_ids = get_all_page_ids();" then we go on with a foreach loop that will obviously return a nasty warning if used when there is no page created.

Attachments (1)

2313.diff (613 bytes) - added by davidhouse 20 years ago.

Download all attachments as: .zip

Change History (5)

#1 @ryan
20 years ago

  • Owner changed from anonymous to ryan

@davidhouse
20 years ago

#2 @davidhouse
20 years ago

  • Keywords bg|has-patch added

#3 @ryan
20 years ago

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

(In [3467]) Make sure we have an array. Props Ozh and David House. fixes #2313

#4 @(none)
20 years ago

  • Milestone 2.0.1 deleted

Milestone 2.0.1 deleted

Note: See TracTickets for help on using tickets.