Allow the building of STI associations #5813

Closed
wants to merge 1 commit into
from
Commits on Nov 28, 2012
  1. Added STI support to init and building associations

    diminish7 authored and Jason Rush committed Apr 5, 2012
    Allows you to do BaseClass.new(:type => "SubClass") as well as
    parent.children.build(:type => "SubClass") or parent.build_child
    to initialize an STI subclass. Ensures that the class name is a
    valid class and that it is in the ancestors of the super class
    that the association is expecting.