From 08ef4c23d7ed2c969b17b622af397a3d69474ef5 Mon Sep 17 00:00:00 2001 From: Hypolite Petovan Date: Thu, 2 May 2019 13:08:06 -0400 Subject: [PATCH] Replace last references to removed HTTPException->httpcode property --- include/api.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/api.php b/include/api.php index 698fa2f995..f360dc4116 100644 --- a/include/api.php +++ b/include/api.php @@ -364,7 +364,7 @@ function api_call(App $a) Logger::warning(API_LOG_PREFIX . 'not implemented', ['module' => 'api', 'action' => 'call']); throw new NotImplementedException(); } catch (HTTPException $e) { - header("HTTP/1.1 {$e->httpcode} {$e->httpdesc}"); + header("HTTP/1.1 {$e->getCode()} {$e->httpdesc}"); return api_error($type, $e); } } @@ -384,7 +384,7 @@ function api_error($type, $e) /// @TODO: https://dev.twitter.com/overview/api/response-codes $error = ["error" => $error, - "code" => $e->httpcode . " " . $e->httpdesc, + "code" => $e->getCode() . " " . $e->httpdesc, "request" => $a->query_string]; $return = api_format_data('status', $type, ['status' => $error]); -- 2.39.5