Rails, production-env, “Object is not missing constant”

后端 未结 4 1631
借酒劲吻你
借酒劲吻你 2021-01-15 11:17

So I seems I was stupid and haven\'t checked running in production-env for a long time, and now that I\'m trying to deploy, I\'m getting this annoying error. Any ideas?

4条回答
  •  傲寒
    傲寒 (楼主)
    2021-01-15 11:35

    I can't say if this is a typo or the real code but:

    class User < InheritedResources::Base
      include HistoryTools
    end
    

    Should probably be

    class User < ActiveRecord::Base
      include HistoryTools
    end
    

    InheritedResources should be used for controllers, not models.

提交回复
热议问题