X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=lib%2Fhttpclient.php;h=4c3af8d7dd950fd1b23a4988e3710f8148f93ef8;hb=cac6d4234a4ef8fea1d487f44062ae06dd9c0c52;hp=3f82620761c6eef8d953cc11fa9611addad5ba96;hpb=5581143bee602dbd5417f532f2b483e58d0a4269;p=quix0rs-gnu-social.git diff --git a/lib/httpclient.php b/lib/httpclient.php index 3f82620761..4c3af8d7dd 100644 --- a/lib/httpclient.php +++ b/lib/httpclient.php @@ -81,12 +81,13 @@ class HTTPResponse extends HTTP_Request2_Response } /** - * Check if the response is OK, generally a 200 status code. + * Check if the response is OK, generally a 200 or other 2xx status code. * @return bool */ function isOk() { - return ($this->getStatus() == 200); + $status = $this->getStatus(); + return ($status >= 200 && $status < 300); } }