Skip to content

Commit 2164b31

Browse files
committed
PaymentTransaction methods for resolving order status are now more universal
1 parent 4468b2f commit 2164b31

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/Model/Payment/Transaction/PaymentTransaction.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -179,15 +179,15 @@ public function getRefundableAmount(): Money
179179
*/
180180
public function isRefundable(): bool
181181
{
182-
return $this->payment->isGoPay() && in_array($this->externalPaymentStatus, [PaymentStatus::PARTIALLY_REFUNDED, PaymentStatus::PAID], true);
182+
return in_array($this->externalPaymentStatus, [PaymentStatus::PARTIALLY_REFUNDED, PaymentStatus::PAID], true);
183183
}
184184

185185
/**
186186
* @return bool
187187
*/
188188
public function isPartiallyRefunded(): bool
189189
{
190-
return $this->payment->isGoPay() && $this->externalPaymentStatus === PaymentStatus::PARTIALLY_REFUNDED;
190+
return $this->externalPaymentStatus === PaymentStatus::PARTIALLY_REFUNDED;
191191
}
192192

193193
/**
@@ -199,7 +199,7 @@ public function isPaid(): bool
199199
return false;
200200
}
201201

202-
return $this->payment->isGoPay() && $this->externalPaymentStatus === PaymentStatus::PAID;
202+
return $this->externalPaymentStatus === PaymentStatus::PAID;
203203
}
204204

205205
/**
@@ -211,6 +211,6 @@ public function hasPaymentInProcess(): bool
211211
return false;
212212
}
213213

214-
return $this->payment->isGoPay() && $this->externalPaymentStatus === PaymentStatus::PAYMENT_METHOD_CHOSEN;
214+
return $this->externalPaymentStatus === PaymentStatus::PAYMENT_METHOD_CHOSEN;
215215
}
216216
}

0 commit comments

Comments
 (0)