rails / acts_as_list

NOTICE: official repository moved to https://github.com/swanandp/acts_as_list

Home Page:http://rubyonrails.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Usage with abstract classes

bright4 opened this issue · comments

When acts_as_list is used on an abstract class, which has multiple subclasses, in some cases the plugin tries to get the order of the items in the abstract class.

This of course fails (the table cannot be found).

My solution was to add a check for this:

def acts_as_list(options = {})
    return if abstract_class
    ...