Re: [Rails-core] [PATCH] add optional count parameter to pluralize

2006-07-21 Thread Caio Chassot
On 2006-07-21, at 13:37 , Mislav Marohnić wrote: There is already a view helper with that functionality. Is it needed outside of views? That would be the helper I mentioned in the fragment you quoted. :P I use active_support outside of rails somewhat often, and that's where I need it.

Re: [Rails-core] [PATCH] add optional count parameter to pluralize

2006-07-21 Thread Mislav Marohnić
There is already a view helper with that functionality. Is it needed outside of views?On 7/20/06, Caio Chassot < [EMAIL PROTECTED]> wrote:Inspired by the pluralize method in the text_helper, here's a patch that adds an optional count parameter to Inflector.pluralize. ___

[Rails-core] [PATCH] add optional count parameter to pluralize

2006-07-20 Thread Caio Chassot
Inspired by the pluralize method in the text_helper, here's a patch that adds an optional count parameter to Inflector.pluralize. Example from the tests: assert_equal 'foos', s.pluralize assert_equal 'foos', s.pluralize(0) assert_equal 'foo', s.pluralize(1) assert_equal 'foos'