Opened 12 years ago
Closed 12 years ago
#21184 closed defect (bug) (fixed)
$comment global var is not set when wp_list_comments is called with callback function
Reported by: | sirzooro | Owned by: | ryan |
---|---|---|---|
Milestone: | 3.5 | Priority: | normal |
Severity: | normal | Version: | 2.7 |
Component: | Comments | Keywords: | has-patch |
Focuses: | Cc: |
Description
Many comments-related functions (mainly template ones) uses comment object stored in global variable $comment
, when they are called without parameters. However when you try to use wp_list_comments()
with custom callback function, this is not true. Currently template authors have to either set this global var in their callback functions, or explicitly pass comment object to functions like comment_text()
. Attached path fixes this.
Attachments (1)
Change History (3)
Note: See
TracTickets for help on using
tickets.
In [21324]: