Make WordPress Core

Opened 16 years ago

Closed 16 years ago

#14528 closed enhancement (fixed)

Set no_found_rows = true in get_posts()

Reported by: scribu Owned by:
Priority: normal Milestone: 3.1
Component: Performance Version:
Severity: normal Keywords: has-patch commit
Cc: Focuses:

Description (last modified by scribu)

When using get_posts(), you have no way of accesing $wp_query->found_posts, making the SELECT FOUND_ROWS() query useless.

So, the no_found_rows flag should always be set.

Attachments (1)

no_found_rows.diff​ (387 bytes ) - added by scribu 16 years ago.

Download all attachments as: .zip

Change History (3)

#1 @scribu
16 years ago

  • Description modified (diff)

#2 @scribu
16 years ago

  • Resolution → fixed
  • Status new → closed

(In [15548]) Always set no_found_rows = true in get_posts(). Fixes #14528

Note: See TracTickets for help on using tickets.