Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Paramete for getDecimalAmount not used #31

Open
simonbuehler opened this issue Jul 8, 2022 · 0 comments
Open

Paramete for getDecimalAmount not used #31

simonbuehler opened this issue Jul 8, 2022 · 0 comments

Comments

@simonbuehler
Copy link

Hi,

the getDecimalAmount method seems to be off, the $scale parameter isn't used at all, only $this->scale?

money/src/Money.php

Lines 84 to 90 in 66edcbd

public function getDecimalAmount($scale = 2): string
{
return $this->instance
->getAmount()
->dividedBy($this->getDivider(), $this->scale, static::$roundingMode)
->toScale($this->scale, static::$roundingMode);
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

1 participant