follower_lib.rb 244 Bytes Edit Raw Blame History 1 2 3 4 5 6 7 8 9 10 11 12 13 module FollowerLib private # Retrieves the parent class name if using STI. def parent_class_name(obj) if obj.class.superclass != ActiveRecord::Base return obj.class.superclass.name end return obj.class.name end end