mirror of
https://github.com/v2board/v2board.git
synced 2025-01-27 00:19:10 +08:00
opt paytaro error report
This commit is contained in:
parent
168b0ad72e
commit
9dc64114f5
@ -24,7 +24,8 @@ class PayTaro
|
|||||||
$curl->post('https://api.paytaro.com/v1/gateway/fetch', http_build_query($params));
|
$curl->post('https://api.paytaro.com/v1/gateway/fetch', http_build_query($params));
|
||||||
$result = $curl->response;
|
$result = $curl->response;
|
||||||
if ($curl->error) {
|
if ($curl->error) {
|
||||||
abort(500, $result->errors[array_keys($result->errors)[0]]);
|
$errors = (array)$result->errors;
|
||||||
|
abort(500, $errors[array_keys($errors)[0]][0]);
|
||||||
}
|
}
|
||||||
$curl->close();
|
$curl->close();
|
||||||
if (!isset($result->data->trade_no)) {
|
if (!isset($result->data->trade_no)) {
|
||||||
|
Loading…
Reference in New Issue
Block a user