#35356 closed defect (bug) (fixed)
wp_list_comments ignores $comments parameter
Reported by: |
|
Owned by: |
|
---|---|---|---|
Milestone: | 4.4.2 | Priority: | high |
Severity: | normal | Version: | 4.6 |
Component: | Comments | Keywords: | fixed-major |
Focuses: | Cc: |
Description
Introduced in [36157].
This update does not check if a custom $comments array was provided before determining that a new comment query needs to be made.
If a comment array is provided, wp_list_comments shouldn't make a new query and should always use the provided comments.
Attachments (2)
Change History (9)
#1
@
9 years ago
- Keywords needs-patch added
- Milestone changed from Awaiting Review to 4.4.2
- Owner set to boonebgorges
- Priority changed from normal to high
- Status changed from new to assigned
#2
follow-up:
↓ 3
@
9 years ago
- Keywords has-patch needs-testing added; needs-patch removed
Thanks for the patch, @ivankristianto. It's frustrating that the separate_comments()
logic has to be reproduced, but like you, I can't see a better way of doing it without rewriting the whole function.
35356.diff cleans up the formatting of the patch, and adds a unit test that demonstrates the issue. @felser or someone else having the problem, can you verify that the patch fixes the issue for you?
#3
in reply to:
↑ 2
@
9 years ago
Replying to boonebgorges:
It's frustrating that the
separate_comments()
logic has to be reproduced
Totally agree with you. It does repeated 3 times.
@felser Thanks for the ticket. You're correct that this is due to [36157] - it was an oversight on my part. It should just be a matter of moving the added logic inside the
else
block right below it, but this will need unit tests.