Browse Source

Merge branch 'hotfix/hotfix_1250_2'

master
Guillaume Bourgeois 1 year ago
parent
commit
9fe0bb1ebd
1 changed files with 7 additions and 1 deletions
  1. +7
    -1
      common/logic/User/UserProducer/Service/UserProducerBuilder.php

+ 7
- 1
common/logic/User/UserProducer/Service/UserProducerBuilder.php View File

@@ -64,7 +64,13 @@ class UserProducerBuilder extends AbstractBuilder

public function updateCredit(Payment $payment): void
{
if($payment->user) {
if($payment->user && (
$payment->getType() == Payment::TYPE_DEBIT
|| $payment->getType() == Payment::TYPE_CREDIT
|| ($payment->getType() == Payment::TYPE_PAYMENT && $this->paymentSolver->isMeanPaymentCredit($payment))
|| ($payment->getType() == Payment::TYPE_REFUND && $this->paymentSolver->isMeanPaymentCredit($payment))
)) {
$userProducer = $this->userProducerRepository->findOneUserProducer($payment->user);

if ($userProducer) {

Loading…
Cancel
Save