diff --git a/lib/active_hash/base.rb b/lib/active_hash/base.rb index 043d140..464fa44 100644 --- a/lib/active_hash/base.rb +++ b/lib/active_hash/base.rb @@ -64,9 +64,7 @@ def field_names # # => ["id", "name", "code"] # def column_names - field_names.map do |field| - field.respond_to?(:name) ? field.name : field.to_s.freeze - end + field_names.map(&:name) end def the_meta_class