Merge pull request #8386 from ptibogxiv/patch-21
FIX support for stripeconnect mode
This commit is contained in:
commit
f75334f131
@ -79,7 +79,7 @@ if (! empty($conf->stripe->enabled))
|
||||
if (! empty($conf->global->STRIPE_LIVE) && ! GETPOST('forcesandbox','alpha'))
|
||||
{
|
||||
$service = 'StripeLive';
|
||||
$servicestatus = 0;
|
||||
$servicestatus = 1;
|
||||
}
|
||||
|
||||
$stripe = new Stripe($db);
|
||||
@ -602,7 +602,7 @@ if (empty($reshook))
|
||||
elseif ($action == 'setassourcedefault')
|
||||
{
|
||||
try {
|
||||
$cu = \Stripe\Customer::retrieve($stripecu);
|
||||
$cu=$stripe->customerStripe($object->id, $stripeacc, $servicestatus);
|
||||
$cu->default_source = (string) $source;
|
||||
$result = $cu->save();
|
||||
|
||||
@ -618,7 +618,7 @@ if (empty($reshook))
|
||||
elseif ($action == 'deletecard')
|
||||
{
|
||||
try {
|
||||
$cu = \Stripe\Customer::retrieve($stripecu);
|
||||
$cu=$stripe->customerStripe($object->id, $stripeacc, $servicestatus);
|
||||
|
||||
$cu->sources->retrieve("$source")->detach();
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user