开发者

uninitialized constant ActiveSupport::Concern

开发者 https://www.devze.com 2023-03-23 09:56 出处:网络
I got below link to solve problem related to class and instance method. http://www.fakingfantastic.com/2010/09/20/concerning-yourse开发者_Python百科lf-with-active-support-concern/

I got below link to solve problem related to class and instance method. http://www.fakingfantastic.com/2010/09/20/concerning-yourse开发者_Python百科lf-with-active-support-concern/

module NotificationsHelper
  extend ActiveSupport::Concern

  module ClassMethods
    def my_class_method
      # ...
    end
  end

  module InstanceMethods
    def my_instance_method
      # ...
    end
  end
end

But I am getting uninitialized constant ActiveSupport::Concern error. I am using Rails 2.3.5 and Ruby 1.9.2p180


This module is only available in Rails 3 onwards

0

精彩评论

暂无评论...
验证码 换一张
取 消