[wp-trac] [WordPress Trac] #47706: Typo in comments reply observer, new comments don't get events attached
WordPress Trac
noreply at wordpress.org
Mon Jul 15 16:10:36 UTC 2019
#47706: Typo in comments reply observer, new comments don't get events attached
--------------------------+-----------------------------
Reporter: maguiar | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Comments | Version: trunk
Severity: normal | Keywords:
Focuses: javascript |
--------------------------+-----------------------------
There's a typo in the comment's reply link observer. It's supposed to
observe DOM changes inside `body` so it can attach the reply link event to
new nodes. However, Core has it written as:
{{{
var observerOptions = {
childList: true,
subTree: true
};
}}}
`subTree` should be `subtree`. Because of this new comments added with
ajax don't get the event attached to them, and the reply link directs
instead to whatever the reply link points to. While the rest of comments
open the reply form below the comment.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/47706>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list