X-Git-Url: http://git.jankratochvil.net/?p=MyWeb.git;a=blobdiff_plain;f=Web.pm;h=2b632a72233813dd55754568b8636337ad9e0e5a;hp=202ecd99cc81bf03ad2fca8fa8a462fe53ec1090;hb=04827f7491b1728301be5317da58c1f16f095663;hpb=c8dccbabbbd73dcf3b25bddf5e8557d7551dd6c4 diff --git a/Web.pm b/Web.pm index 202ecd9..2b632a7 100644 --- a/Web.pm +++ b/Web.pm @@ -319,7 +319,7 @@ sub remote_ip () # As 'Apache::ForwardedFor' takes the first of $ENV{"HTTP_X_FORWARDED_FOR"} # while the contents is '127.0.0.1, 213.220.195.171' if client has its own proxy. # We must take the last item ourselves. - my $r=$ENV{"HTTP_X_FORWARDED_FOR"} || $W->{"r"}->remote_host(); + my $r=$ENV{"HTTP_X_FORWARDED_FOR"} || $W->{"r"}->get_remote_host(); $r=~s/^.*,\s*//; return $r; }