'Flat comments' setting issue: pasted comments sometimes are not in the expected place
>>> [!note] Migrated issue
<!-- Drupal.org comment -->
<!-- Migrated from issue #2269753. -->
Reported by: [extexan](https://www.drupal.org/user/473302)
>>>
<h3 id="summary-problem-motivation">Problem/Motivation</h3>
<p>Sometimes the pasted comments are not in the expected place on the bottom of the thread.</p>
<h3 id="summary-proposed-resolution">Proposed resolution</h3>
<p>When the 'flat comments' setting is choosen, the comments are sorting by it's cid column. If the comment id of the pasted comment is less then the cid of the comments in the node's comments hierarhy, the comment will appears on the top or in the middle of the existing comments, not on the bottom.</p>
<h3 id="summary-remaining-tasks">Remaining tasks</h3>
<p>We need to change the drupal core sorting comments function to get rid of the sorting by cid.</p>
<h3 id="summary-api-changes">Original issue submitted by ExTexan:</h3>
<p>When I first tried this module, it seemed to work fine - that is, it moved the comments (and attached replies) as advertised. However, the last couple of times I've used it, the comments get cut, but not pasted.</p>
<p>The first time that happened, I had cut many comments, most of which had "reply-to" comments, so I thought, "Ok, that was too much for it."</p>
<p>Since then, I've tried cutting a single comment, but when I paste it, it's completely gone.</p>
<p>Also, if I'm remembering correctly, I read somewhere that this module is also supposed to allow for a topic (node) to be moved to a "comment" in another thread, but I can't figure out how to do so. Please advise.</p>
issue