Closed chriscz closed 3 years ago
Hey @chriscz,
This is a somewhat unexpected use case, since we never intended for ActiveType::Record to extend something that is not itself an ActiveRecord or ActiveType::Object. In the case of Authlogic::Session::Base, it kind of works, since that class mimicks ActiveRecord::Base to some extent.
I think adding the sti_name method in that specific case is the correct solution.
After updating from 1.8.0 to 1.9.0 he following breaks with an undefined
sti_name
error, I think the fix could be justchecking whether the extended classrespond_to? :sti_name
and if not, rather usingname
.For now I just added a
sti_name
method on the authlogic session.