no message

This commit is contained in:
hellcat 2025-04-13 18:21:37 +08:00
parent 4f79cfe48a
commit fa0f028bae
2 changed files with 14 additions and 6 deletions

View File

@ -125,11 +125,19 @@ final class Epay extends Base
'ret' => 1,
'msg' => '订单发起成功,正在跳转到支付页面...',
]);
} catch (Exception|GuzzleException) {
return $response->withJson([
'ret' => 0,
'msg' => '请求支付失败',
]);
} catch (Exception|GuzzleException $e) {
if ($user["is_admin"] == 1) {
return $response->withJson([
'ret' => 0,
'msg' => json_encode($e->getMessage()),
]);
} else {
return $response->withJson([
'ret' => 0,
'msg' => '请求支付失败',
]);
}
}
}

View File

@ -22,7 +22,7 @@ final class VisitorCount
} else {
$sFrom = $_ENV['short_url'] . "/";
$sFrom = "隐藏";
}