# File lib/enumerated_attribute/integrations/active_record.rb, line 24 def read_enumerated_attribute(name) name = name.to_s #if not enumerated - let active record handle it return read_attribute(name) unless self.class.has_enumerated_attribute?(name) #if enumerated, is it an active record attribute, if not, the value is stored in an instance variable name_sym = name.to_sym return instance_variable_get('@'+name) unless self.has_attribute?(name) #this is an enumerated active record attribute val = read_attribute(name) val = val.to_sym if !!val val end