diff --git a/README.md b/README.md index 9ea549b..e410f36 100644 --- a/README.md +++ b/README.md @@ -65,7 +65,9 @@ if ($response->isSuccessful()) { $bankTransactionRef = $response->getTransactionReference(); $websiteOrderId = $response->getTransactionId(); +} elseif ($response->isPending()) { + // Do temporary things until we get a success/failed tranaction response. } else { echo $response->getMessage(); } -``` \ No newline at end of file +``` diff --git a/src/Message/CompletePurchaseResponse.php b/src/Message/CompletePurchaseResponse.php index afe6717..ba2f10f 100644 --- a/src/Message/CompletePurchaseResponse.php +++ b/src/Message/CompletePurchaseResponse.php @@ -67,7 +67,7 @@ protected function decomposeData() */ public function isSuccessful() { - return $this->isValid() && in_array($this->getCode(), array('00', '60')); + return $this->isValid() && $this->getCode() === '00'; } /** @@ -203,4 +203,4 @@ public function getTransactionId() { return $this->fields['orderId']; } -} \ No newline at end of file +}