diff --git a/extend/catcher/library/Errors.php b/extend/catcher/library/Errors.php index 4c752ed..82db53e 100644 --- a/extend/catcher/library/Errors.php +++ b/extend/catcher/library/Errors.php @@ -152,6 +152,8 @@ class Errors '45157' => '标签名非法,请注意不能和其他标签重名', '45158' => '标签名长度超过30个字节', '45056' => '创建的标签数过多,请注意不能超过100个', + '45058' => '不能修改0/1/2这三个系统默认保留的标签', + '45057' => '该标签下粉丝数超过10w,不允许直接删除', '9001001' => 'POST 数据参数不合法', '9001002' => '远端服务不可用', '9001003' => 'Ticket 不合法', diff --git a/extend/catcher/library/WeChat.php b/extend/catcher/library/WeChat.php index ad9cd06..2d8f446 100644 --- a/extend/catcher/library/WeChat.php +++ b/extend/catcher/library/WeChat.php @@ -66,7 +66,8 @@ class WeChat public static function throw($response) { if (isset($response['errcode']) && $response['errcode']) { - throw new WechatResponseException(Errors::WECHAT[$response['errcode']], $response['errcode']); + $message = Errors::WECHAT[$response['errcode']] ?? $response['errcode']; + throw new WechatResponseException($message, $response['errcode']); } return $response;