Skip to content

Commit

Permalink
[bug-OpenMage#790] NPE in Mage_Directory_Model_Currency::convert()
Browse files Browse the repository at this point in the history
  • Loading branch information
rafdol authored and edannenberg committed Oct 25, 2019
1 parent 6c625c0 commit 912214b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/code/core/Mage/Directory/Model/Currency.php
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,7 @@ public function convert($price, $toCurrency = null)
}

throw new Exception(Mage::helper('directory')->__('Undefined rate from "%s-%s".', $this->getCode(),
$toCurrency->getCode()));
$toCurrency instanceof Mage_Directory_Model_Currency ? $toCurrency->getCode() : $toCurrency));
}

/**
Expand Down

0 comments on commit 912214b

Please sign in to comment.