diff --git a/app/lib/client/Ucloud.php b/app/lib/client/Ucloud.php index 23f0a1f..b2bf886 100644 --- a/app/lib/client/Ucloud.php +++ b/app/lib/client/Ucloud.php @@ -27,7 +27,7 @@ class Ucloud $param = array_merge($param, $params); $param['Signature'] = $this->ucloudSignature($param); $ua = sprintf("PHP/%s PHP-SDK/%s", phpversion(), self::VERSION); - $response = get_curl($this->ApiUrl, json_encode($param), 0, 0, $ua, 0, ['Content-Type: application/json']); + $response = get_curl($this->ApiUrl, json_encode($param), 0, 0, $ua, 0, ['Content-Type' => 'application/json']); $result = json_decode($response, true); if (isset($result['RetCode']) && $result['RetCode'] == 0) { return $result; diff --git a/app/service/OptimizeService.php b/app/service/OptimizeService.php index ced2048..27dabda 100644 --- a/app/service/OptimizeService.php +++ b/app/service/OptimizeService.php @@ -57,7 +57,7 @@ class OptimizeService 'key' => config_get('optimize_ip_key', 'o1zrmHAF'), 'type' => $ip_type, ]; - $response = get_curl($url, json_encode($params), 0, 0, 0, 0, ['Content-Type: application/json; charset=UTF-8']); + $response = get_curl($url, json_encode($params), 0, 0, 0, 0, ['Content-Type' => 'application/json; charset=UTF-8']); $arr = json_decode($response, true); if (isset($arr['code']) && $arr['code'] == 200) { return $arr['info']; diff --git a/app/utils/MsgNotice.php b/app/utils/MsgNotice.php index 6e251fe..8d86f78 100644 --- a/app/utils/MsgNotice.php +++ b/app/utils/MsgNotice.php @@ -220,7 +220,7 @@ class MsgNotice if (!$wechat_apptoken || !$wechat_appuid) return false; $url = 'https://wxpusher.zjiecode.com/api/send/message'; $post = ['appToken' => $wechat_apptoken, 'content' => $content, 'summary' => $title, 'contentType' => 3, 'uids' => [$wechat_appuid]]; - $result = get_curl($url, json_encode($post), 0, 0, 0, 0, ['Content-Type: application/json; charset=UTF-8']); + $result = get_curl($url, json_encode($post), 0, 0, 0, 0, ['Content-Type' => 'application/json; charset=UTF-8']); $arr = json_decode($result, true); if (isset($arr['success']) && $arr['success'] == true) { return true; @@ -284,7 +284,7 @@ class MsgNotice } else { return '不支持的Webhook地址'; } - $result = get_curl($url, json_encode($post), 0, 0, 0, 0, ['Content-Type: application/json; charset=UTF-8']); + $result = get_curl($url, json_encode($post), 0, 0, 0, 0, ['Content-Type' => 'application/json; charset=UTF-8']); $arr = json_decode($result, true); if (isset($arr['errcode']) && $arr['errcode'] == 0 || isset($arr['code']) && $arr['code'] == 0) { return true;