gmail.js icon indicating copy to clipboard operation
gmail.js copied to clipboard

Email messages in a thread has is_deleted=true even if they are not deleted

Open rrb11 opened this issue 10 years ago • 1 comments

In a 4 mail thread when I opened the second mail its show me is_deleted=true. Even the mail was not deleted. Its start happening after 3 mail in a thread and after that the is_deleted=true number was increase.

rrb11 avatar May 18 '15 16:05 rrb11

I am able to account for deleted items in a thread with this code:

        const openItem = $(newElement)
          .closest('.h7[role="listitem"]')
        // siblings no height = deleted thread items (not present in total_threads)
        const siblings = openItem
          .parent()
          .children('[role="listitem"]')
          .filter((_, e) => $(e).height())
        let emailPosition = siblings.index(openItem) // search email container, get offset of message in un-deleted thread items
        // get thread item from (undeleted) thread list
        let email = this.openedEmailDetails.threads[this.openedEmailDetails.total_threads[emailPosition]]

It's pretty jankity. I would prefer a better solution that includes a list of messages in a thread that includes deleted messages instead of having to skip over messages with height=0

revmischa avatar Feb 15 '18 09:02 revmischa

Old issue is old. Closing.

josteink avatar Oct 11 '23 08:10 josteink