File tree Expand file tree Collapse file tree 2 files changed +158
-248
lines changed
app/code/Magento/Config/Model/Config/Backend/Currency
dev/tests/integration/testsuite/Magento/Config/Console/Command Expand file tree Collapse file tree 2 files changed +158
-248
lines changed Original file line number Diff line number Diff line change @@ -54,7 +54,8 @@ public function __construct(
54
54
public function afterSave ()
55
55
{
56
56
$ exceptions = [];
57
- foreach ($ this ->_getAllowedCurrencies () as $ currencyCode ) {
57
+ $ allowedCurrencies = $ this ->_getAllowedCurrencies ();
58
+ foreach ($ allowedCurrencies as $ currencyCode ) {
58
59
if (!in_array ($ currencyCode , $ this ->_getInstalledCurrencies ())) {
59
60
$ exceptions [] = __ (
60
61
'Selected allowed currency "%1" is not available in installed currencies. ' ,
@@ -63,7 +64,7 @@ public function afterSave()
63
64
}
64
65
}
65
66
66
- if (!in_array ($ this ->_getCurrencyDefault (), $ this -> _getAllowedCurrencies () )) {
67
+ if (!in_array ($ this ->_getCurrencyDefault (), $ allowedCurrencies )) {
67
68
$ exceptions [] = __ (
68
69
'Default display currency "%1" is not available in allowed currencies. ' ,
69
70
$ this ->_localeCurrency ->getCurrency ($ this ->_getCurrencyDefault ())->getName ()
You can’t perform that action at this time.
0 commit comments