Skip to content
This repository has been archived by the owner on Feb 20, 2023. It is now read-only.

Commit

Permalink
Merge pull request #41 from mageplaza/2.4-develop
Browse files Browse the repository at this point in the history
2.4 develop
  • Loading branch information
haitv282 authored Sep 12, 2022
2 parents 225aff1 + fc3ecbd commit c82a228
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion Plugin/AbstractFormat.php
Original file line number Diff line number Diff line change
Expand Up @@ -236,7 +236,7 @@ public function getSubjectRate($subject, $row)
if ($rate = $subject->getColumn()->getRate()) {
return (float) $rate;
}
if ($rate = $row->getData($subject->getColumn()->getRateField())) {
if ($subject->getColumn()->getRateField() && $rate = $row->getData($subject->getColumn()->getRateField())) {
return (float) $rate;
}

Expand Down
2 changes: 1 addition & 1 deletion Plugin/Directory/PriceCurrency.php
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ public function aroundRound(DirectoryPriceCurrency $subject, callable $proceed,
return $proceed($price);
}

return round($price, $this->getPrecision());
return round((float)$price, $this->getPrecision());
}

/**
Expand Down
4 changes: 2 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@
"name": "mageplaza/module-currency-formatter",
"description": "Magento 2 Currency Formatter Extension",
"require": {
"mageplaza/module-core": "^1.4.5"
"mageplaza/module-core": "^1.4.12"
},
"type": "magento2-module",
"version": "4.0.6",
"version": "4.0.7",
"license": "proprietary",
"authors": [
{
Expand Down

0 comments on commit c82a228

Please sign in to comment.