Skip to content
Snippets Groups Projects
Commit 94b3227d authored by Prasad's avatar Prasad
Browse files

Fixed: String * String disallowed in PHP 8.1

parent 6d354896
No related branches found
No related tags found
No related merge requests found
......@@ -415,7 +415,7 @@ class CurrencyField {
public static function convertFromDollar($amount, $conversionRate) {
$currencyField = new CurrencyField($amount);
return round($amount * $conversionRate, $currencyField->maxNumberOfDecimals);
return round( (float)$amount * (float)$conversionRate, $currencyField->maxNumberOfDecimals);
}
/** This function returns the amount converted from master currency.
......@@ -423,7 +423,7 @@ class CurrencyField {
* param $crate - conversion rate.
*/
public static function convertFromMasterCurrency($amount, $conversionRate) {
return $amount * $conversionRate;
return (float)$amount * (float)$conversionRate;
}
function currencyDecimalFormat($value, $user = null){
......@@ -464,4 +464,4 @@ class CurrencyField {
}
}
}
?>
\ No newline at end of file
?>
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment