Hook that prevents a second root from being created.
# File lib/sequel/plugins/tree.rb, line 138 138: def before_save 139: if self[model.parent_column].nil? && (root = model.root) && pk != root.pk 140: raise TreeMultipleRootError, "there is already a root #{model.name} defined" 141: end 142: super 143: end
Disabled; run with --debug to generate this.
Generated with the Darkfish Rdoc Generator 1.1.6.