ActiveType 2.0 released
We released2.0 with breaking changes:
Casting is prevented when the base record has changes in its already loaded associations, because those would be lost. Option
force: truecan be used to override this and still do the cast (this is not recommended).
After casting, the base record will not be usable any more. The base record and the newly created casted record share state which is unexpected. Option
force: truecan be used to override this, so the base record is still usable (this is not recommended).
Example for the
force: true option:
sign_up = ActiveType.cast(user, SignUp, force: true)