diff --git a/lib/plugins/acts_as_tree/lib/active_record/acts/tree.rb b/lib/plugins/acts_as_tree/lib/active_record/acts/tree.rb index 4e5f37182..d069da972 100644 --- a/lib/plugins/acts_as_tree/lib/active_record/acts/tree.rb +++ b/lib/plugins/acts_as_tree/lib/active_record/acts/tree.rb @@ -47,6 +47,8 @@ module ActiveRecord has_many :children, :class_name => name, :foreign_key => configuration[:foreign_key], :order => configuration[:order], :dependent => configuration[:dependent] scope :roots, where("#{configuration[:foreign_key]} IS NULL").order(configuration[:order]) + + send :include, ActiveRecord::Acts::Tree::InstanceMethods end end