diff --git a/app/model/PayAccount.php b/app/model/PayAccount.php index c5a24f9..c1453be 100644 --- a/app/model/PayAccount.php +++ b/app/model/PayAccount.php @@ -37,7 +37,7 @@ class PayAccount extends BaseModel foreach ($payplugin_config as $config) { $option[$config['platform']] = $config['name']; } - return $option[$value]; + return isset($option[$value]) ? $option[$value] : '[已卸载,请停用]'; } public function getPatternAttr($value) { diff --git a/extend/ImgCaptcha.php b/extend/ImgCaptcha.php index a8ea520..9736177 100644 --- a/extend/ImgCaptcha.php +++ b/extend/ImgCaptcha.php @@ -23,7 +23,7 @@ class ImgCaptcha return $captcha; } // 请求外部资源 - private function getHttpResponse($url, $header = [], $post = null, $timeout = 10) + private static function getHttpResponse($url, $header = [], $post = null, $timeout = 10) { $ch = curl_init($url); curl_setopt($ch, CURLOPT_TIMEOUT, $timeout);