diff options
author | Florian Pritz <bluewind@xinu.at> | 2018-10-14 22:49:10 +0200 |
---|---|---|
committer | Florian Pritz <bluewind@xinu.at> | 2018-12-07 00:35:04 +0100 |
commit | 6c5fcdfbe3594b7311ab0bea417fc68f2eb9337d (patch) | |
tree | e1e990d2ca64a2ba7bfaba0d229e0ed2324e9765 /Bugzilla/WebService/Server/REST.pm | |
parent | fba8176ed56c92410e972bbced00eb9183f68369 (diff) | |
download | bugzilla-6c5fcdfbe3594b7311ab0bea417fc68f2eb9337d.tar.gz bugzilla-6c5fcdfbe3594b7311ab0bea417fc68f2eb9337d.tar.xz |
Revert "Bug 1495741 - memory issues: Avoid copying stuff in the webservice layer so much"harmony-master
Fix an "Unexpected Error" message when viewing a bug.
This reverts commit 5688d0e712b85bc892ce405a1b79e3571f6d6d0f.
Signed-off-by: Florian Pritz <bluewind@xinu.at>
Diffstat (limited to 'Bugzilla/WebService/Server/REST.pm')
-rw-r--r-- | Bugzilla/WebService/Server/REST.pm | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/Bugzilla/WebService/Server/REST.pm b/Bugzilla/WebService/Server/REST.pm index 781960c68..5f0839734 100644 --- a/Bugzilla/WebService/Server/REST.pm +++ b/Bugzilla/WebService/Server/REST.pm @@ -54,7 +54,7 @@ sub handle { # unless we were looking for OPTIONS if (!$self->_find_resource($self->cgi->path_info)) { if ($self->request->method eq 'OPTIONS' && $self->bz_rest_options) { - my $response = $self->response_header(STATUS_OK, ""); + my $response = $self->response_header(STATUS_OK, ""); my $options_string = join(', ', @{$self->bz_rest_options}); $response->header( 'Allow' => $options_string, @@ -165,7 +165,6 @@ sub response { my $template = Bugzilla->template; $content = ""; - $result->encode if blessed $result; $template->process("rest.html.tmpl", {result => $result}, \$content) || ThrowTemplateError($template->error()); @@ -508,7 +507,7 @@ sub _get_content_prefs { # Parse the Accept header, and save type name, score, and position. my @accept_types = split /,/, $self->cgi->http('accept') || ''; - my $order = 0; + my $order = 0; for my $accept_type (@accept_types) { my ($weight) = ($accept_type =~ /q=(\d\.\d+|\d+)/); my ($name) = ($accept_type =~ m#(\S+/[^;]+)#); |