From 462bca55b88b5d39385555e1fe986f1d86fa231b Mon Sep 17 00:00:00 2001 From: Matthew Wilson Date: Thu, 12 May 2005 21:35:33 +0000 Subject: [PATCH] - fix [ 1182630 ] thread::isMarkedRead should check thread's lastpost,not self --- lib/WebGUI/Asset/Post/Thread.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/WebGUI/Asset/Post/Thread.pm b/lib/WebGUI/Asset/Post/Thread.pm index 55b2db3c0..9e2781862 100644 --- a/lib/WebGUI/Asset/Post/Thread.pm +++ b/lib/WebGUI/Asset/Post/Thread.pm @@ -380,7 +380,7 @@ Returns a boolean indicating whether this thread is marked read for the user. sub isMarkedRead { my $self = shift; return 1 if $self->isPoster; - my ($isRead) = WebGUI::SQL->quickArray("select count(*) from Post_read where userId=".quote($session{user}{userId})." and threadId=".quote($self->getId)); + my ($isRead) = WebGUI::SQL->quickArray("select count(*) from Post_read where userId=".quote($session{user}{userId})." and threadId=".quote($self->getId)." and postId=".quote($self->get("lastPostId")); return $isRead; }