All Versions
23
Latest Version
Avg Release Cycle
93 days
Latest Release
561 days ago

Changelog History
Page 1

  • v0.7.0 Changes

    October 06, 2022

    ๐Ÿ’ฅ ๐Ÿ’ฅ Breaking changes

    • JSON extension is now required for PHP 7.4 (always available with PHP >= 8.0)
    • ๐Ÿ‘ AbstractMoney is now officially sealed, extending it yourself is not supported

    ๐Ÿ†• โœจ New features

    • Money and RationalMoney now implement JsonSerializable
  • v0.6.0 Changes

    August 02, 2022

    ๐Ÿ’ฅ ๐Ÿ’ฅ Breaking changes

    • Minimum PHP version is now 7.4
    • AbstractMoney::getAmount() now has a return type
    • 0๏ธโƒฃ CurrencyConverter's constructor does not accept a default $context anymore
    • CurrencyConverter::convert() now requires the $context previously accepted by the constructor as third parameter
    • Money::allocateWithRemainder() now refuses to allocate a portion of the amount that cannot be spread over all ratios, and instead adds that amount to the remainder (#55)
    • Money::splitWithRemainder() now behaves like allocateWithRemainder()

    ๐Ÿ†• โœจ New ISO currencies

    • SLE (Leone) in Sierra Leone (SL)

    ๐Ÿ‘Œ ๐Ÿ‘Œ Improvements

    • Compatibility with brick/math version 0.10
  • v0.5.2 Changes

    April 03, 2021

    ๐Ÿ†• โœจ New methods

    • Money::allocateWithRemainder()
    • Money::splitWithRemainder()

    These methods perform like their allocate() and split() counterparts, but append the remainder at the end of the returned array instead of spreading it over the first monies.

    Thanks @NCatalani!

  • v0.5.1 Changes

    February 10, 2021

    ๐Ÿ‘Œ ๐Ÿ‘Œ Improvement

    BaseCurrencyProvider now always returns a BigNumber for convenience (#37). This is useful if you're using BaseCurrencyProvider on its own, not just in CurrencyConverter.

    Thanks @rdarcy1!

  • v0.5.0 Changes

    August 19, 2020

    ๐Ÿฑ ๐Ÿ‘Œ Improvements

    • compatibility with brick/math version 0.9

    โš ๏ธ Caution

    ๐Ÿ‘ป When using brick/math version 0.9, the Money factory methods such as of() and ofMinor() now accept decimal numbers in the form .123 and 123., and do not throw an exception anymore in this case.

  • v0.4.5 Changes

    May 31, 2020

    ๐Ÿ› ๐Ÿ› Bug fix

    ๐Ÿ‘ป MoneyBag::getAmount(), add() and subtract() would throw an exception when using a custom currency.

  • v0.4.4 Changes

    January 23, 2020

    ๐Ÿ†• โœจ New method

    AbstractMoney::isAmountAndCurrencyEqualTo() compares a money to another. (#17)

    This method is different from isEqualTo() in 2 aspects:

    • it only accepts another money, not a raw number;
    • it returns false if the money is in another currency , instead of throwing an exception.
  • v0.4.3 Changes

    January 09, 2020

    ๐Ÿ›  Improvements

    • MoneyBag::getAmount() now accepts an ISO numeric currency code as well

    ๐Ÿ†• โœจ New methods

    • CurrencyConverter::convertToRational() converts to a RationalMoney (#22)
  • v0.4.2 Changes

    July 04, 2019

    ๐ŸŽ Performance improvement when calling Money::formatTo() many times for the same locale.

  • v0.4.1 Changes

    October 17, 2018

    โž• Added support for brick/math version 0.8.