Skip to content

Commit

Permalink
PLUG-106: Fix pending logic
Browse files Browse the repository at this point in the history
  • Loading branch information
lighe committed May 9, 2024
1 parent aa8e223 commit 6dbbc05
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Model/Webapi/Pending.php
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ public function checkOrderPlaced(string $token): bool
{
try {
$transaction = $this->transactionRepository->getByPaymentUuid($token);
return (bool)$transaction->getOrderId();
return $transaction->getStatus() === 'payment_settled';
} catch (InputException|NoSuchEntityException $e) {
return false;
}
Expand Down
2 changes: 1 addition & 1 deletion Observer/OrderPlacedHandler.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ class OrderPlacedHandler implements ObserverInterface
*/
public function __construct(
OrderRepositoryInterface $orderRepository,
LogRepository $logRepository,
LogRepository $logRepository
) {
$this->orderRepository = $orderRepository;
$this->logRepository = $logRepository;
Expand Down

0 comments on commit 6dbbc05

Please sign in to comment.