using has_ancestry in subclass throws error #87

Closed
jtromp opened this Issue Feb 28, 2012 · 1 comment

Projects

None yet

2 participants

@jtromp
jtromp commented Feb 28, 2012

When I add "has_ancestry" in a subclass of another class (that inherites from ActiveRecord:Base), an error is thrown in development mode:

Mysql::Error: Table 'AUTHORABLE.groups' doesn't exist: SHOW FIELDS FROM groups

The class hierarchy in this case is: ActiveRecord::Base > Authorable > Group

The Group class has "has_ancestry" defined. Is this expected behaviour, or is there a solution? I could not find anything related to this in the documentation.

@StefanH StefanH pushed a commit that closed this issue May 7, 2013
Stefan Henzen Added test to see if 4e57f32 fixes #87 (which it does) 0cc1c0f
@StefanH StefanH closed this in 0cc1c0f May 7, 2013
@StefanH
Collaborator
StefanH commented May 7, 2013

This was caused by ancestry overwriting base_class. It no longer does that in 2.0, thanks to 4e57f32

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment