Enforce_available_locales exception for number_helpers

I have an application in dutch only, hence the config.i18n.available_locales = [:nl].

However - a small country as we are - we have to communicate with external APIs in english. Therefor I need to use number_with_precision(amount, locale: :en)

This raises an InvalidLocale exception due to the default config.i18n.enforce_available_locales= true configuration. So to be able to use the number_with_precision() function in english I have to fully unset this configuration which opens the door for abuse.

Is there a another option - or would it not be better to be able to explicitly pass a force_local: true with the NumberHelpers to override this behaviour? As I explicitly set the locale (no user parameter) abuse should not be possible. Correct?

Any chance you could send the delimiter and separator into the helper instead of the locale and be explicit in these instances instead of relying on the locale?

That’s definitely the solution to go for at this moment but it makes setting the locale explicitly a little useless - in my opinion - as it’s the current locale by default.

Thanks for your reply!