Make WordPress Core

Opened 14 years ago

Closed 14 years ago

#21058 closed defect (bug) (fixed)

Undefined variable in mw.getRecentPosts

Reported by: maxcutler Owned by: nacin
Priority: low Milestone: 3.5
Component: XML-RPC Version: 1.5
Severity: trivial Keywords: has-patch commit
Cc: Focuses:

Description

The $struct variable is not defined before being used in mw_getRecentPosts method.

The first reference is within a for loop, and then it is referenced again outside of the for loop, where it is technically undefined. While PHP figures out the intended behavior, this is invalid code and generates notices.

Attachments (1)

21058.patch (436 bytes ) - added by maxcutler 14 years ago.

Download all attachments as: .zip

Change History (3)

@maxcutler
14 years ago

#1 @nacin
14 years ago

  • Keywords commit added
  • Milestone Awaiting Review3.5

#2 @nacin
14 years ago

  • Owner set to nacin
  • Resolutionfixed
  • Status newclosed

In [21158]:

Initialize a variable. props maxcutler. fixes #21058.

Note: See TracTickets for help on using tickets.