i am having some trouble with paper_trail gem. I love using it and it has nice features. It works fine when i run my server in development and test environments, but displays "undefined local variable or method `has_paper_trail' " error when i start to run the server in production environment. I couldn't be able to figure it out. help please?

有帮助吗?

解决方案 2

thanx vinod, your answer was helpful, but i just solved it by adding production as follows in /config/application.rb

Bundler.require(*Rails.groups(:assets => %w(development test production)))

it works fine.

其他提示

Check configuration :

If you defined in /config/application.rb like

Bundler.require(*Rails.groups(:assets => %w(development test)))

Change to :

Bundler.require(:default, Rails.env)

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top