lib/global_registry_bindings/model/relationship.rb in global-registry-bindings-0.1.2 vs lib/global_registry_bindings/model/relationship.rb in global-registry-bindings-0.1.3

- old
+ new

@@ -8,11 +8,11 @@ def relationship_attributes_to_push(type) entity_attributes = relationship_columns_to_push(type).map do |name, t| relationship_value_for_global_registry(name, t) end.compact.to_h - unless global_registry_relationship(type).exclude_fields.include?(:client_integration_id) + unless global_registry_relationship(type).exclude.include?(:client_integration_id) entity_attributes[:client_integration_id] = global_registry_relationship(type).client_integration_id end entity_attributes[:client_updated_at] = updated_at.to_s(:db) if respond_to?(:updated_at) entity_attributes end @@ -56,13 +56,13 @@ .columns .collect do |c| { c.name.underscore.to_sym => normalize_relationship_column_type(c.type, c.name) } end # rubocop:disable Style/MultilineBlockChain .reduce(&:merge) - .reject { |k, _v| global_registry_relationship(type).exclude_fields.include? k } - .merge(global_registry_relationship(type).extra_fields) + .reject { |k, _v| global_registry_relationship(type).exclude.include? k } + .merge(global_registry_relationship(type).fields) else - global_registry_relationship(type).extra_fields || {} + global_registry_relationship(type).fields || {} end end end end end