Committer: mchervonniy
LJSUP-8605: reply link was removed from spammed commentU trunk/bin/upgrading/s2layers/smoothsailing/layout.s2
Modified: trunk/bin/upgrading/s2layers/smoothsailing/layout.s2 =================================================================== --- trunk/bin/upgrading/s2layers/smoothsailing/layout.s2 2011-04-21 09:13:32 UTC (rev 10422) +++ trunk/bin/upgrading/s2layers/smoothsailing/layout.s2 2011-04-21 09:23:35 UTC (rev 10423) @@ -1787,28 +1787,31 @@ } function Comment::print_linkbar() { + var Page p = get_page(); """ <div class="commentLinkbar"><ul> """; # reply to, parent, thread links. """<li>"""; - if($.screened == true) { - ### if comment screened - show link for unscreen - var Link link; - $link = $this->get_link("unscreen_to_reply"); - """<a href="$link.url" title="$link.caption">$link.caption</a>"""; - } else { - ### showing reply link if comment not screened - if (not $.frozen) { - $this->print_reply_link({ "linktext" => $*text_comment_reply }); - } - } + if ((not $.spam) or ($p.showspam)) { + if($.screened == true) { + ### if comment screened - show link for unscreen + var Link link; + $link = $this->get_link("unscreen_to_reply"); + """<a href="$link.url" title="$link.caption">$link.caption</a>"""; + } else { + ### showing reply link if comment not screened + if (not $.frozen) { + $this->print_reply_link({ "linktext" => $*text_comment_reply }); + } + } + } ##$this->print_reply_link({"linktext" => $*text_comment_reply}); """</li>"""; if ($.parent_url!="") { print safe """<li><a href="$.parent_url">$*text_comment_parent</a></li>"""; } - if ($.thread_url!="") { + if ($.thread_url!="" and (not $.spam)) { print safe """<li><a href="$.thread_url">$*text_comment_thread</a></li>"""; $this->print_expand_collapse_links(); }