def read_attribute(key)
      key = key.to_s
      if attributes.key? key
        value = attributes[key]
      elsif links.key?(key) && self.class.reflect_on_association(key)
        value = attributes[key] = follow_link key
      end
      value
    end
def read_attribute(key)
      key = key.to_s
      if attributes.key? key
        value = attributes[key]
      elsif links.key?(key) && self.class.reflect_on_association(key)
        value = attributes[key] = follow_link key
      end
      value
    end
The value of a specified attribute, lazily fetching any defined
 association.

 @param key [Symbol, String] The name of the attribute to be fetched.
 @example
   account.read_attribute :first_name # => "Ted"
   account[:last_name]                # => "Beneke"
 @see #write_attribute