Commit d0b85510 by 庄欣

fix bug

parent b6f549a7
......@@ -94,7 +94,7 @@ class CurlClient
}
curl_setopt($http,CURLOPT_HTTPHEADER,$this->header);
curl_setopt($http,CURLOPT_POSTFIELDS,$this->data);
if ($this->method === "GET") {
/*if ($this->method === "GET") {
$NOW_TIME = time();
static $response_from_api;
$sign = $this->getSign();
......@@ -111,10 +111,10 @@ class CurlClient
}
}
$res = $response_from_api[$sign];
} else {
} else {*/
$res = curl_exec($http);
$curlinfo = curl_getinfo($http);
}
//}
if ($curlinfo == false || (is_array($curlinfo) && $curlinfo['http_code'] != 200)) {
var_dump($res);
throw new \Exception("返回错误");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment