mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2024-09-20 08:21:34 +02:00
Static analysis
This commit is contained in:
parent
b81eb57744
commit
08f9443c82
@ -163,7 +163,7 @@ class PaymentMethod implements MethodInterface
|
||||
|
||||
return $this->processPendingPayment($response['id'], (float) $response['amount'], PaymentType::ACSS , $customer->token);
|
||||
} catch(\Throwable $e) {
|
||||
$this->processUnsuccessfulPayment( new InvalidResponseException($e->getMessage(), (int) $e->getCode()) );
|
||||
$this->processUnsuccessfulPayment( new \Exception($e->getMessage(), (int) $e->getCode()) );
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -136,11 +136,9 @@ class RotessaPaymentDriver extends BaseDriver
|
||||
$result = $this->gatewayRequest("get","customers/{$contact->id}");
|
||||
$result = $result->json();
|
||||
|
||||
$this->client = Client::find($contact->client_id);
|
||||
$this->client = Client::query()->find($contact->client_id);
|
||||
|
||||
$customer = array_merge($result, ['id' => $contact->id, 'custom_identifier' => $contact->custom_identifier ]);
|
||||
// $customer = (new Customer($result))->additional( ['id' => $contact->id, 'custom_identifier' => $contact->custom_identifier ]); //creates a new customer in rotessa
|
||||
// $this->findOrCreateCustomer($customer->additional + $customer->jsonSerialize());
|
||||
|
||||
$this->findOrCreateCustomer($customer);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user