diff --git a/app/code/Bitpay/Core/Block/Iframe.php b/app/code/Bitpay/Core/Block/Iframe.php index 757f0d2..67d938b 100755 --- a/app/code/Bitpay/Core/Block/Iframe.php +++ b/app/code/Bitpay/Core/Block/Iframe.php @@ -74,9 +74,12 @@ public function getCartUrl() { return $cartUrl; } - public function isTestMode() - { - return $this->_scopeConfig->getValue('payment/bitpay/fullscreen', \Magento\Store\Model\ScopeInterface::SCOPE_STORE); + public function isTestMode() { + $mode = $this -> _scopeConfig -> getValue('payment/bitpay/network', \Magento\Store\Model\ScopeInterface::SCOPE_STORE); + if ($mode == 'testnet') { + return true; + } + return false; } diff --git a/app/code/Bitpay/Core/view/frontend/templates/bitpay/iframe.phtml b/app/code/Bitpay/Core/view/frontend/templates/bitpay/iframe.phtml index 4bf8214..8c7d02b 100755 --- a/app/code/Bitpay/Core/view/frontend/templates/bitpay/iframe.phtml +++ b/app/code/Bitpay/Core/view/frontend/templates/bitpay/iframe.phtml @@ -1,6 +1,6 @@ getFrameActionUrl(); -$isNotTest = $block->isTestMode(); +$isTest = $block->isTestMode(); $parts = parse_url($url); parse_str($parts['query'], $query); ?> @@ -8,8 +8,8 @@ parse_str($parts['query'], $query);