Opened 17 years ago
Closed 17 years ago
#11966 closed defect (bug) (fixed)
Sticky posts not removed from query results when pushed to front of posts
| Reported by: | jeffstieler | Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | 3.0 |
| Component: | General | Version: | 2.9.1 |
| Severity: | normal | Keywords: | has-patch tested |
| Cc: | Focuses: |
Description
array_search() is being used to determine the offset of a processed sticky post in the query results, and array_splice() is being used to remove it from the queue.
array_search() returns the key for the sticky post, and array_splice() expects a numerical index
If the key returned by array_search() does not match the sticky post's actual offset in the array, it is not removed and appears as a duplicate.
Attachments (1)
Change History (3)
Note:
See TracTickets
for help on using tickets.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
Confirmed.
To test, add a filter to 'option_sticky_posts' that returns the array with keys set, ie; apply something like array_diff() to the sticky_posts array.