diff options
author | Frédéric Buclin <LpSolit@gmail.com> | 2012-01-05 01:41:46 +0100 |
---|---|---|
committer | Frédéric Buclin <LpSolit@gmail.com> | 2012-01-05 01:41:46 +0100 |
commit | 9dbc12f52fbcbc7e48a8b7cbe45302bd36d256d3 (patch) | |
tree | ce812a0875c01ee1237944604bc8324fe8bd64e6 /Bugzilla/WebService | |
parent | a25730da0b3ef9ea4e99af4e0d99117a81a9b8ed (diff) | |
download | bugzilla-9dbc12f52fbcbc7e48a8b7cbe45302bd36d256d3.tar.gz bugzilla-9dbc12f52fbcbc7e48a8b7cbe45302bd36d256d3.tar.xz |
Bug 706753: Bugzilla will not work with newest version of JSON::RPC 1.01 due to non-backward compatibility
r=dkl r=mkanat a=LpSolit
Diffstat (limited to 'Bugzilla/WebService')
-rw-r--r-- | Bugzilla/WebService/Server/JSONRPC.pm | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/Bugzilla/WebService/Server/JSONRPC.pm b/Bugzilla/WebService/Server/JSONRPC.pm index 8fe724080..3b232aafa 100644 --- a/Bugzilla/WebService/Server/JSONRPC.pm +++ b/Bugzilla/WebService/Server/JSONRPC.pm @@ -22,7 +22,18 @@ package Bugzilla::WebService::Server::JSONRPC; use strict; -use base qw(JSON::RPC::Server::CGI Bugzilla::WebService::Server); +use Bugzilla::WebService::Server; +BEGIN { + our @ISA = qw(Bugzilla::WebService::Server); + + if (eval { require JSON::RPC::Server::CGI }) { + unshift(@ISA, 'JSON::RPC::Server::CGI'); + } + else { + require JSON::RPC::Legacy::Server::CGI; + unshift(@ISA, 'JSON::RPC::Legacy::Server::CGI'); + } +} use Bugzilla::Error; use Bugzilla::WebService::Constants; |