fix(addon): alipay 及 wechatpay 没有判断支付类型
This commit is contained in:
@@ -16,16 +16,16 @@ class PayClose
|
||||
*/
|
||||
public function handle($params)
|
||||
{
|
||||
// if ($params["pay_type"] == "alipay") {
|
||||
try {
|
||||
$pay_model = new PayModel($params[ 'site_id' ]);
|
||||
$result = $pay_model->close($params);
|
||||
return $result;
|
||||
} catch (\Exception $e) {
|
||||
return error(-1, $e->getMessage());
|
||||
} catch (\Throwable $e) {
|
||||
return error(-1, $e->getMessage());
|
||||
if ($params["pay_type"] == "alipay") {
|
||||
try {
|
||||
$pay_model = new PayModel($params[ 'site_id' ]);
|
||||
$result = $pay_model->close($params);
|
||||
return $result;
|
||||
} catch (\Exception $e) {
|
||||
return error(-1, $e->getMessage());
|
||||
} catch (\Throwable $e) {
|
||||
return error(-1, $e->getMessage());
|
||||
}
|
||||
}
|
||||
// }
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user