diff options
author | Sarven Capadisli <csarven@status.net> | 2010-02-10 11:09:03 +0000 |
---|---|---|
committer | Sarven Capadisli <csarven@status.net> | 2010-02-10 11:09:03 +0000 |
commit | 3d0bc1a3dd16826bf89286f37aa3778e93a34b6b (patch) | |
tree | 917cbd6dde0d9b47497def39e9dcf12e5433e544 /lib/httpclient.php | |
parent | f3c2dfacf4b3b1ce44edcb82d8e76e75e2b7c9fa (diff) | |
parent | e8428d1d525677fa116236735a43e7b49e8a3fd3 (diff) |
Merge branch '0.9.x' of git@gitorious.org:statusnet/mainline into 0.9.x
Diffstat (limited to 'lib/httpclient.php')
-rw-r--r-- | lib/httpclient.php | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/httpclient.php b/lib/httpclient.php index 3f8262076..4c3af8d7d 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); } } |