wallet batch polishing

This commit is contained in:
omair saleh
2022-02-06 22:02:34 +08:00
parent 25d9fb3cfc
commit 89a51e6fbd
2 changed files with 2 additions and 2 deletions
@@ -88,7 +88,7 @@ class CallbackBillplzLogic
$this->updatesTransactionStatus->execute($transaction, $status);
if($transaction->owner instanceof Wallet) {
if($transaction->owner instanceof Wallet && $billPlz->state === ApprovalStatus::APPROVED) {
$this->updatesWalletBalance->execute($transaction->owner, $transaction->amount);
}
@@ -18,7 +18,7 @@ class UpdatesWalletBalance extends AbstractUpdateRecord
*/
public function execute(Wallet $model, $amount) {
$model->amount = $model + $amount;
$model->amount = $model->amount + $amount;
return $this->handler($model);
}