Closed pda closed 13 years ago
Hi, Paul.
I just released the patch for this issue. We mainly use this gem with Ruby on Rails and/or Mongoid, and both already require I18n, that's why the "explicit" require was missing.
Thanks for pointing it and sorry for the delay to release the patch.
Cheers! Three days turnaround is plenty fast when you're doing it for free :)
I18n is being depended on by
Duration#format
but notrequire
d anywhere.Something in the test environment seems to be indirectly loading I18n, but I'm not sure what. Either way, in Rails and in the tests, it's loaded elsewhere, so the bug is not apparent.
However, outside of these environments:
Can be fixed by loading i18n:
Tested with Ruby 1.9.2p0 on Linux and Mac OS.
Thanks for picking up the reins from the old duration gem.. apart from being abandoned it seems to be broken under Ruby 1.9 because of multi-byte chars declared in a US-ASCII context.. or something.
Cheers! Paul