summaryrefslogtreecommitdiff
path: root/inc/HTTPClient.php
diff options
context:
space:
mode:
authorGina Haeussge <osd@foosel.net>2008-12-07 01:19:00 +0100
committerGina Haeussge <osd@foosel.net>2008-12-07 01:19:00 +0100
commitab91b35c28866e6a69b28a3a57bfad235e2f79bb (patch)
treed98ad5abb417ce00fe8aecbb87b442285b5bfa41 /inc/HTTPClient.php
parenta603991337642936bef49bd248085f0cc0c6161b (diff)
downloadrpg-ab91b35c28866e6a69b28a3a57bfad235e2f79bb.tar.gz
rpg-ab91b35c28866e6a69b28a3a57bfad235e2f79bb.tar.bz2
HTTP client should accept all HTTP response codes in the 200 range
darcs-hash:20081207001900-2b4f5-5d2e6fca1c443884fe7901074be7220c655d0f4a.gz
Diffstat (limited to 'inc/HTTPClient.php')
-rw-r--r--inc/HTTPClient.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/inc/HTTPClient.php b/inc/HTTPClient.php
index 8ff206444..6b3663eaa 100644
--- a/inc/HTTPClient.php
+++ b/inc/HTTPClient.php
@@ -122,7 +122,7 @@ class HTTPClient {
function get($url,$sloppy304=false){
if(!$this->sendRequest($url)) return false;
if($this->status == 304 && $sloppy304) return $this->resp_body;
- if($this->status != 200) return false;
+ if($this->status < 200 || $this->status > 206) return false;
return $this->resp_body;
}
@@ -135,7 +135,7 @@ class HTTPClient {
*/
function post($url,$data){
if(!$this->sendRequest($url,$data,'POST')) return false;
- if($this->status != 200) return false;
+ if($this->status < 200 || $this->status > 206) return false;
return $this->resp_body;
}