]> Sergey Matveev's repositories - public-inbox.git/commitdiff
view: rely on internal query parser for 'o' param
authorEric Wong <e@80x24.org>
Sat, 2 Jul 2016 07:56:37 +0000 (07:56 +0000)
committerEric Wong <e@80x24.org>
Sat, 2 Jul 2016 07:57:29 +0000 (07:57 +0000)
Plack::Request will check the request body by merely
calling "param", totally unnecessary and sneaky.

lib/PublicInbox/View.pm

index fd882aa031f3be3f4751c77bad077a75cfab788a..1527959d52fe05fe1721b511263d1c08e8751d4b 100644 (file)
@@ -908,7 +908,7 @@ sub emit_topics {
 
 sub emit_index_topics {
        my ($ctx) = @_;
-       my ($off) = (($ctx->{cgi}->param('o') || '0') =~ /(\d+)/);
+       my ($off) = (($ctx->{qp}->{o} || '0') =~ /(\d+)/);
        $ctx->{order} = [];
        $ctx->{subjs} = {};
        $ctx->{latest} = {};