diff --git a/README.md b/README.md
index ccd8616..f5f3032 100644
--- a/README.md
+++ b/README.md
@@ -11,8 +11,8 @@ This repository contains the OpenCart PostFinance Checkout payment module that
## Documentation
-* [English](https://plugin-documentation.postfinance-checkout.ch/pfpayments/opencart-2.1/1.0.5/docs/en/documentation.html)
+* [English](https://plugin-documentation.postfinance-checkout.ch/pfpayments/opencart-2.1/1.0.6/docs/en/documentation.html)
## License
-Please see the [license file](https://github.com/pfpayments/opencart-2.1/blob/1.0.5/LICENSE) for more information.
\ No newline at end of file
+Please see the [license file](https://github.com/pfpayments/opencart-2.1/blob/1.0.6/LICENSE) for more information.
\ No newline at end of file
diff --git a/docs/en/documentation.html b/docs/en/documentation.html
index 6b8510b..4a3c6b0 100644
--- a/docs/en/documentation.html
+++ b/docs/en/documentation.html
@@ -21,7 +21,7 @@
Documentation
-
+
Source
@@ -48,7 +48,7 @@
-
-
Download the extension.
+Download the extension.
-
Extract the files and upload the content of the Upload
directory into the root directory of your store using FTP/SSH.
diff --git a/upload/system/library/postfinancecheckout/service/transaction.php b/upload/system/library/postfinancecheckout/service/transaction.php
index f771a1e..9bd2399 100644
--- a/upload/system/library/postfinancecheckout/service/transaction.php
+++ b/upload/system/library/postfinancecheckout/service/transaction.php
@@ -18,15 +18,19 @@ class Transaction extends AbstractService {
public function getPaymentMethods(array $order_info){
$cart_id = \PostFinanceCheckoutVersionHelper::getCurrentCartId($this->registry);
- if (!$cart_id || !isset(self::$possible_payment_method_cache[$cart_id])) {
+ if (!$cart_id || !array_key_exists($cart_id, self::$possible_payment_method_cache)) {
$transaction = $this->update($order_info, false);
- $payment_methods = $this->getTransactionService()->fetchPossiblePaymentMethods($transaction->getLinkedSpaceId(), $transaction->getId());
-
- foreach ($payment_methods as $payment_method) {
- MethodConfiguration::instance($this->registry)->updateData($payment_method);
+ try{
+ $payment_methods = $this->getTransactionService()->fetchPossiblePaymentMethods($transaction->getLinkedSpaceId(), $transaction->getId());
+ foreach ($payment_methods as $payment_method) {
+ MethodConfiguration::instance($this->registry)->updateData($payment_method);
+ }
+ self::$possible_payment_method_cache[$cart_id] = $payment_methods;
+ }
+ catch(\Exception $e) {
+ self::$possible_payment_method_cache[$cart_id] = array();
+ throw $e;
}
-
- self::$possible_payment_method_cache[$cart_id] = $payment_methods;
}
return self::$possible_payment_method_cache[$cart_id];
}