X-Git-Url: http://git.vanrenterghem.biz/git.ikiwiki.info.git/blobdiff_plain/f1a70921e3bfc0496b5564582a5a1463b7a98c09..7a1d5632b8c762ad7b00e1e834b5678ec9299bda:/IkiWiki/Plugin/blogspam.pm diff --git a/IkiWiki/Plugin/blogspam.pm b/IkiWiki/Plugin/blogspam.pm index 626c8ec42..8db3780e8 100644 --- a/IkiWiki/Plugin/blogspam.pm +++ b/IkiWiki/Plugin/blogspam.pm @@ -18,6 +18,7 @@ sub getsetup () { plugin => { safe => 1, rebuild => 0, + section => "auth", }, blogspam_pagespec => { type => 'pagespec', @@ -57,6 +58,7 @@ sub checkconfig () { sub checkcontent (@) { my %params=@_; + my $session=$params{session}; if (exists $config{blogspam_pagespec}) { return undef @@ -87,7 +89,7 @@ sub checkcontent (@) { push @options, "exclude=stopwords"; my %req=( - ip => $ENV{REMOTE_ADDR}, + ip => $session->remote_addr(), comment => defined $params{diff} ? $params{diff} : $params{content}, subject => defined $params{subject} ? $params{subject} : "", name => defined $params{author} ? $params{author} : "",