Skip to:
Content

BuddyPress.org

Opened 11 years ago

Closed 11 years ago

#5154 closed defect (bug) (fixed)

Semantic error in BP_Component::include()

Reported by: mboynes's profile mboynes Owned by: boonebgorges's profile boonebgorges
Milestone: 1.9 Priority: normal
Severity: normal Version:
Component: Core Keywords:
Cc:

Description

In BP_Component::include(), a list of possible filenames are generated in an array, then the array is looped through and if the file exists, it is "required". Then there is a "continue" statement, presumably to exit the loop. This should be a break. Patch attached.

Attachments (1)

bp-core-component.diff (395 bytes) - added by mboynes 11 years ago.

Download all attachments as: .zip

Change History (3)

#1 @boonebgorges
11 years ago

  • Milestone changed from Awaiting Review to 1.9

Good catch.

#2 @boonebgorges
11 years ago

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

In 7355:

break rather than continue when file is found in BP_Component::includes()

When we find the first instance of a file, there's no need to check the
rest of the members of the array - thus a break.

Fixes #5154

Props mboynes

Note: See TracTickets for help on using tickets.