Throw some 404s
This commit is contained in:
parent
8473f2f2d9
commit
f5637f65e7
|
@ -151,6 +151,9 @@ group {
|
|||
my $remarks =
|
||||
$c->remark->get_remarks_by_thread_id($thread_id, $this_page);
|
||||
|
||||
# Probably a better way to do this 404 stuff I reckon
|
||||
|
||||
# Check for existence of thread
|
||||
if (my $thread_body = %$thread{'body'}) {
|
||||
$c->stash(
|
||||
thread => $thread,
|
||||
|
@ -167,6 +170,9 @@ group {
|
|||
)
|
||||
}
|
||||
|
||||
# Check for existance of remark page number
|
||||
$c->stash(status => 404) unless $remarks->[0] || 1 >= $this_page;
|
||||
|
||||
$c->render();
|
||||
};
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue