sub err_txt {
my ($ctx, $err) = @_;
my $u = '//xapian.org/docs/queryparser.html';
- $u = PublicInbox::Hval::prurl($ctx->{cgi}->{env}, $u);
+ $u = PublicInbox::Hval::prurl($ctx->{env}, $u);
$err =~ s/^\s*Exception:\s*//; # bad word to show users :P
$err = ascii_html($err);
"\nBad query: <b>$err</b>\n" .
$ctx->{git_dir} = $obj->{mainrepo};
$ctx->{git} = $obj->git;
# for PublicInbox::HTTP::weaken_task:
- $ctx->{cgi}->{env}->{'pi-httpd.inbox'} = $obj;
+ $ctx->{env}->{'pi-httpd.inbox'} = $obj;
$ctx->{-inbox} = $obj;
$ctx->{inbox} = $inbox;
return;
# generation and link things intended for nntp:// to https?://,
# so try to infer links and redirect them to the appropriate
# list URL.
- $self->news_www->call($ctx->{cgi}->{env});
+ $self->news_www->call($ctx->{env});
}
# returns undef if valid, array ref response if invalid
$ctx->{footer} = join("\n",
'- ' . $desc,
"A <a\nhref=\"" .
- PublicInbox::Hval::prurl($ctx->{cgi}->{env}, PI_URL) .
+ PublicInbox::Hval::prurl($ctx->{env}, PI_URL) .
'">public-inbox</a>, ' .
'anybody may post in plain-text (not HTML):',
$addr,
} elsif ($path_info =~ m!$INBOX_RE/(\S+/\S+)/f\z!o) {
r301($ctx, $1, $2);
} else {
- $self->news_www->call($ctx->{cgi}->{env});
+ $self->news_www->call($ctx->{env});
}
}
sub r301 {
my ($ctx, $inbox, $mid, $suffix) = @_;
- my $cgi = $ctx->{cgi};
my $obj = $ctx->{-inbox};
unless ($obj) {
my $r404 = invalid_inbox($ctx->{www}, $ctx, $inbox);