The expected behavior is that when a user deletes a message thread, it does not appear in that user's inbox. If a thread recipient then replies to this deleted thread, the thread is "recreated" with the reply as the first message in the thread. (For all other users, the complete thread is kept intact).

This behavior works as expected if any recipients delete the thread. If the initial thread author deletes the thread, however, future replies do not "recreate" the thread in the user's inbox. The number of unread messages returned by privatemsg_unread_count shows the unread message, but the thread itself does not show up in the inbox, resulting in a "ghost" unread message.

I've looked in the code, specifically privatemsg_sql_list, and couldn't find anything that seems out of the ordinary, especially because it doesn't look like the original author is treated any differently than any other recipients.

Does anyone have any ideas about what might be causing this behavior?

Thanks in advance,
Tim Trinidad

CommentFileSizeAuthor
#1 privatemsg.deleted_thread_inbox.patch3.31 KBberdir

Comments

berdir’s picture

Version: 6.x-1.0-rc3 » 6.x-1.0-rc4
Status: Active » Needs work
StatusFileSize
new3.31 KB

Nice catch!

The attached bug should fix it and does also include a test case to detect the bug.

Please test and confirm that it works by setting the issue to RTBC. Thanks.

berdir’s picture

Status: Needs work » Needs review

correct status

timtrinidad’s picture

Status: Needs review » Reviewed & tested by the community

I'm still using 1.0rc3, specifically privatemsg_filter.module v 1.1.2.17. We're planning an upgrade of all our modules next month.

I manually replaced the line in question, and it seems to be working perfectly. Thanks for the (lightning fast) response!

Tim

berdir’s picture

Version: 6.x-1.0-rc4 » 7.x-1.x-dev
Status: Reviewed & tested by the community » Fixed

Fixed in 6.x-1.x-dev and 7.x-1.x-dev.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.