-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
[MoneyBundle] [CurrencyBundle] Add interface for MoneyHelper and repl… #4307
Conversation
* @throws \InvalidArgumentException | ||
*/ | ||
public function formatAmount($amount, $currency = null, $decimal = false, $locale = null); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing blank line at the end of file ;)
@lchrusciel Hey Lukasz, i processed your comments. I also added a interface for CurrencyHelper. Would be weird if we only did the MoneyHelper and not the CurrencyHelper |
|
||
/** | ||
* Convert amount and format it! | ||
* |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess we could get rid of this comment since the method name already says this.
public function __construct( | ||
CurrencyContextInterface $currencyContext, | ||
CurrencyConverterInterface $converter, | ||
MoneyHelperInterface $moneyHelper |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Indent is too small ;)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Moreover, could you put arguments in the same order as class fields? 😄
@lchrusciel does this need anything more to get merged? Let me know. |
It is good to go. Good job 👍 /cc @michalmarcinkowski |
Before we merge that, let's quickly discuss if we want interfaces for all helpers? I would say yes. |
[MoneyBundle] [CurrencyBundle] Add interface for MoneyHelper and repl…
Thank you Axel! 👍 |
[MoneyBundle] [CurrencyBundle] Add interface for MoneyHelper and repl…
[MoneyBundle] [CurrencyBundle] Add interface for MoneyHelper and repl…
…ace specific typehinting to allow overrides