1) Behaviour

Context: A user has set an option to view collapsed comments

Step (a) - View a node (let this node be = x)
Step (b) - View a node (let this node be = y)
Step (c) - Click a collapsed comment link for a node=y comment (let this comment be = z)
Step (d) - Error: Comment z is shown under text of node=x

2) Diagnosis

In comment.module, in function comment_render generation of collapsed links is dependent on the $_SESSION data set by a call to comment_referer_save(). However for a given (ie current) node this call is made after the links have been generated and thus typically they are with reference to the previous node for which comment_render has been called - giving rise to behaviour in (1) above.

3) Treatment

In comment.module function comment_render the call to comment_referer_save(); sould be the 1st action performed in the if (user_access("access comments")) block rather than the last.

Comments

Dries’s picture

Assigned: Unassigned » Dries

Fixed in CVS! Good catch and thanks for the excellent bug report.

Anonymous’s picture

Automatically closed due to inactivity (marked fixed for 14 days).