|
@@ -119,7 +119,12 @@ class Airwallex extends Payment
|
|
|
'verify' => false
|
|
'verify' => false
|
|
|
]);
|
|
]);
|
|
|
$resultObject = json_decode($response->getBody()->getContents());
|
|
$resultObject = json_decode($response->getBody()->getContents());
|
|
|
- return $resultObject;
|
|
|
|
|
|
|
+ if ($resultObject->status != 'SUCCESS') {
|
|
|
|
|
+ throw new \Exception('airwallex api is error');
|
|
|
|
|
+ }
|
|
|
|
|
+ $id = $resultObject->id;
|
|
|
|
|
+ $client_secret = $resultObject->client_secret;
|
|
|
|
|
+ return $id . ':' . $client_secret;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
public function getToken()
|
|
public function getToken()
|