--- loncom/interface/lonwhatsnew.pm 2005/12/15 00:53:29 1.37 +++ loncom/interface/lonwhatsnew.pm 2005/12/15 13:38:58 1.38 @@ -1,5 +1,5 @@ # -# $Id: lonwhatsnew.pm,v 1.37 2005/12/15 00:53:29 raeburn Exp $ +# $Id: lonwhatsnew.pm,v 1.38 2005/12/15 13:38:58 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -635,23 +635,14 @@ sub get_discussions { $hidden = $$discussiondata{$id.':'.$ressymb.':hidden'}; $hiddenflag = 1; } - } - if (grep/^deleted$/,@keys) { + } elsif (grep/^deleted$/,@keys) { unless ($deletedflag) { $deleted = $$discussiondata{$id.':'.$ressymb.':deleted'}; $deletedflag = 1; } - } - if ($deletedflag && $hiddenflag) { - last; - } - } - for (my $id=$version; $id>0; $id--) { - unless (($hidden =~/\.$id\./) || ($deleted =~/\.$id\./)) { - if ($prevread <$$discussiondata{$id.':'.$ressymb.':timestamp'}) { - unless((exists($$discussiondata{$id.':'.$ressymb.':hidden'})) || - (exists($$discussiondata{$id.':'.$ressymb.':deleted'}))) { - + } else { + unless (($hidden =~/\.$id\./) || ($deleted =~/\.$id\./)) { + if ($prevread <$$discussiondata{$id.':'.$ressymb.':timestamp'}) { $unreadcount ++; $$unread{$ressymb}{$unreadcount} = $id.': '. $$discussiondata{$id.':'.$ressymb.':subject'};