diff options
author | Dylan William Hardison <dylan@hardison.net> | 2018-05-19 17:33:46 +0200 |
---|---|---|
committer | Dylan William Hardison <dylan@hardison.net> | 2018-06-28 22:41:56 +0200 |
commit | 216af94b979206ee77d3f3b783648a959b120547 (patch) | |
tree | 8d08425a6b009558c4c1803f8dfba0de0d667fba /Bugzilla/Util.pm | |
parent | 20c6de522aa4d27ba3c3f76d68c0b89424789270 (diff) | |
download | bugzilla-216af94b979206ee77d3f3b783648a959b120547.tar.gz bugzilla-216af94b979206ee77d3f3b783648a959b120547.tar.xz |
more things
Diffstat (limited to 'Bugzilla/Util.pm')
-rw-r--r-- | Bugzilla/Util.pm | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/Bugzilla/Util.pm b/Bugzilla/Util.pm index 8e60944b0..ed1d4593c 100644 --- a/Bugzilla/Util.pm +++ b/Bugzilla/Util.pm @@ -321,8 +321,9 @@ sub do_ssl_redirect_if_required { # Returns the real remote address of the client, sub remote_ip { - if (Bugzilla->usage_mode == USAGE_MODE_QUANTUM) { - return Bugzilla->cgi->controller->tx->remote_address; + my $cgi = Bugzilla->cgi; + if ($cgi->can('controller')) { + return $cgi->controller->tx->remote_address; } else { my $remote_ip = $ENV{'REMOTE_ADDR'} || '127.0.0.1'; |