Make WordPress Core

Opened 11 years ago

Closed 11 years ago

#5019 closed defect (bug) (fixed)

get_next_post() and get_previous_post() are too trusting

Reported by: mdawaffe Owned by: mdawaffe
Milestone: 2.3 Priority: normal
Severity: normal Version: 2.3
Component: General Keywords: has-patch commit
Focuses: Cc:


Both should bail out if there's no current global $post variable to reference.

Attachments (1)

5019.diff (758 bytes) - added by mdawaffe 11 years ago.

Download all attachments as: .zip

Change History (4)

11 years ago

#1 @mdawaffe
11 years ago

  • Keywords has-patch commit added
  • Owner changed from anonymous to mdawaffe
  • Status changed from new to assigned

#2 @Viper007Bond
11 years ago

Looks good.

#3 @ryan
11 years ago

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

(In [6142]) Bail if post is empty. Props mdawaffe. fixes #5019

Note: See TracTickets for help on using tickets.