plural of fee is fees. but Hanami sometimes suggest ves.
sizer opened this issue · comments
Hi there ;)
I found some strange behaviour of Hanami::Utils::String.pluralize
.
Should it be better, for being better Hanami ??? 🤔
Summary
irb(main):003:0> Hanami::Utils::String.pluralize('fee')
=> "fees"
irb(main):004:0> Hanami::Utils::String.pluralize('original_fee')
=> "original_ves"
Description
The plural of fee
is fees
. But with prefix, the plural will be ves
.
It is incorrect behaviour I think... 🤔
this when clause (rule for knife->knives and such, I think) is the cause?
Hi @sizer thanks for this issue, can you try the Hanami::Utils::Inflector
's API?
Hanami::Utils::Inflector.inflections do
exception 'original_fee', 'original_fees'
end
or try to create a PR if you think you can fix this behaviour
Hi, @jodosha . Thanks for fixing this. PR is LGTM. I'll try Hanami@1.3.0 👍
Fixed by #293