Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

Adopt not being honored as an orphan strategy in 1.3.0 #145

Open
chrispatterson opened this Issue · 0 comments

1 participant

@chrispatterson

The current readme indicates that :adopt should be a valid orphan strategy. I get AncestryExceptions when attempting to specify this.

ruby 2.0.0p195 (2013-05-14 revision 40734) / Rails 3.2.13

Don't know whether this is a documentation or feature issue, but my expectation would have been that this would work.

$rails c
2.0.0-p195 :001 > TreeNode.find(:first)
Ancestry::AncestryException: Invalid orphan strategy, valid ones are :rootify, :restrict and :destroy.
class TreeNode < ActiveRecord::Base
  has_ancestry :orphan_strategy => :adopt 
end

Solved my immediate issue by upgrading to ancestry 2.0.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.