summaryrefslogtreecommitdiffstats
path: root/rest.cgi
diff options
context:
space:
mode:
authorDavid Lawrence <dkl@mozilla.com>2015-04-08 19:48:36 +0200
committerDavid Lawrence <dkl@mozilla.com>2015-04-08 19:48:36 +0200
commitdbfd6207290d1eee53fddec4c7c3b4aac0b2d47a (patch)
treeaa190d8cc9e2b313dd7e85bf763c1bfe5502b75d /rest.cgi
parente6d2fb75aa3c183323c534a214f3dd9be5638676 (diff)
downloadbugzilla-dbfd6207290d1eee53fddec4c7c3b4aac0b2d47a.tar.gz
bugzilla-dbfd6207290d1eee53fddec4c7c3b4aac0b2d47a.tar.xz
Bug 1051056: The REST API needs to be versioned so that new changes can be made that do not break compatibility
r=dylan,a=glob
Diffstat (limited to 'rest.cgi')
-rwxr-xr-xrest.cgi11
1 files changed, 2 insertions, 9 deletions
diff --git a/rest.cgi b/rest.cgi
index f12fb64c4..ab985ca79 100755
--- a/rest.cgi
+++ b/rest.cgi
@@ -15,17 +15,10 @@ use lib qw(. lib);
use Bugzilla;
use Bugzilla::Constants;
use Bugzilla::Error;
-use Bugzilla::WebService::Constants;
BEGIN {
- if (!Bugzilla->feature('rest')
- || !Bugzilla->feature('jsonrpc'))
- {
+ if (!Bugzilla->feature('rest')) {
ThrowUserError('feature_disabled', { feature => 'rest' });
}
}
-use Bugzilla::WebService::Server::REST;
Bugzilla->usage_mode(USAGE_MODE_REST);
-local @INC = (bz_locations()->{extensionsdir}, @INC);
-my $server = new Bugzilla::WebService::Server::REST;
-$server->version('1.1');
-$server->handle();
+Bugzilla->api_server->handle();