gettext with rails2.1

Rails2.1でgettext(1.91.0)をつかったところ、以下のようなエラーに


NoMethodError (undefined method `file_exists?' for #):
.
.
.


こちらにその対処方法がありました。

それはconfig/initializers/にgettext.rbというファイルを作って、以下のように記述。


require 'gettext/rails'

module ActionView
class Base
delegate :file_exists?, :to => :finder unless respond_to?(:file_exists?)
end
end




これで2.1でも問題なくgettextを使うことができました。

2008/06/04 by Tomo Nozawa

« Mashup Awards 4th | メイン | iPhone comes to... »

投稿されたコメント:

コメント
  • HTML文法 不許可