lib/koine/attributes.rb in koine-attributes-1.2.1 vs lib/koine/attributes.rb in koine-attributes-1.2.2
- old
+ new
@@ -139,11 +139,11 @@
private :attributes
define_method(:initialize) { |*args| attributes.initialize_values(*args) }
define_method(:inspect) do
- hex_id = format('%x', (object_id << 1))
- "#<#{self.class}:0x00#{hex_id} @attributes=#{attributes.to_h.inspect}>"
+ string = Object.instance_method(:inspect).bind(self).call.split(':')[1].split(' ').first
+ "#<#{self.class}:#{string} @attributes=#{attributes.to_h.inspect}>"
end
end
@_attributes_factory.freeze