% layout 'default'; % title my $thread_id = $thread->{'id'} ? "Thread #$thread_id" : '?';

<%= title %>

<% if (keys %{$thread}) { =%>

<%= $thread->{'title'} %> #<%= $thread->{'id'} %>

<%== markdown $thread->{'body'} =%>
<% if (is_mod) { =%> <% } =%>
<% } =%> <% if (scalar @{$remarks}) { =%>

Remarks

<% for my $remark (@{$remarks}) { =%>

<%= $remark->{'date'} %> <%= link_to "#$remark->{'id'}", single_remark => {remark_id => $remark->{'id'}}, (class => 'post__id') %>

<%== markdown $remark->{'body'} =%>
<% } =%> <% if ($last_page && $last_page != 1) { =%> <% } =%>
<% } =%>