lib/rails_erd/domain/attribute.rb in rails-erd-1.7.1 vs lib/rails_erd/domain/attribute.rb in rails-erd-1.7.2
- old
+ new
@@ -76,11 +76,11 @@
# Returns +true+ if this attribute is used as a foreign key for any
# relationship.
def foreign_key?
@domain.relationships_by_entity_name(@model.name).map(&:associations).flatten.map { |associaton|
- associaton.send(Domain.foreign_key_method_name)
- }.include?(name)
+ associaton.send(Domain.foreign_key_method_name).to_sym
+ }.include?(name.to_sym)
end
# Returns +true+ if this attribute is used for single table inheritance.
# These attributes are typically named +type+.
def inheritance?