Skip to content

Commit

Permalink
Merge pull request #15 from ufukseyithan/master
Browse files Browse the repository at this point in the history
Test mode variable should be a number instead of a boolean when generating the hash
  • Loading branch information
mewebstudio authored Nov 6, 2023
2 parents ff75e1e + b90ef95 commit 394c972
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Payment.php
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ protected function generateHash(): string
$this->order->getEmail() .
$this->order->getFormattedAmount() .
'eft' .
$this->isTestMode();
($this->isTestMode() ? "1" : "0");
}

return $this->config->getMerchantId() .
Expand All @@ -198,7 +198,7 @@ protected function generateHash(): string
$this->order->getNoInstallment() .
$this->order->getMaxInstallment() .
$this->order->getCurrency() .
$this->isTestMode();
($this->isTestMode() ? "1" : "0");
} catch (TypeError $e) {
throw new InvalidOrderDataException($e->getMessage());
}
Expand Down

0 comments on commit 394c972

Please sign in to comment.