active_value 1.0.0 → 1.0.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 5072b5c5ad5e643c3bdc8c9986be317b3badfce1bfce29e79c07795046113957
4
- data.tar.gz: 89956a9fefb5ba8a6e7a4ca70b3bb5cfab527fc0a133d830790659d8a5e99d5d
3
+ metadata.gz: d7b6e5171d472898893d059bd6255cc328f09556e90648d57f2d50666db1df95
4
+ data.tar.gz: 01ebd564d90d24b72d061fc9db40f975d930e86866b74b86fc6911c47745c548
5
5
  SHA512:
6
- metadata.gz: cb9ac9c497dce8199818f4d59a694f8fd8f016313eca4e8a893428d706ab233bf1d01cba0c258258a4b3dcf348c9cebc8a7a8dabd88072fa09043986374d7024
7
- data.tar.gz: e61bc5891f72b87fff0ecf593b0037792cea63e1114f515d2c732e6ebdba47ebe1f55310a9ceef92a1821ff5eafebd008372addd1ed96f1f53c50e8940439451
6
+ metadata.gz: 24c684de542964f56c8ca398ccab44df65e959a7f40c5c2b9c3541db3064ac8433c0179b68bf571af1a97d2e8f74b18b92f974b90c5b949bb11aed98aada7482
7
+ data.tar.gz: 79af7ce2312d5089fdc6d4ecf4b031917674e78d2d45b1832a8d9e8b4f5781ea5744cb5e2528854fa67fcb791b4274b4d2cd035815b0322d284351964e98fd70
@@ -140,7 +140,7 @@ module ActiveValue
140
140
 
141
141
  # Define the equal operator. `A == B` expression means every attribute has same value. (NOT object_id comparison)
142
142
  def ==(another)
143
- self.class.accessors.all? { |attr| public_send(attr) == another.public_send(attr) }
143
+ self.class.accessors.all? { |attr| respond_to?(attr) && another.respond_to?(attr) && public_send(attr) == another.public_send(attr) }
144
144
  end
145
145
  alias_method :eql?, :==
146
146
 
@@ -1,3 +1,3 @@
1
1
  module ActiveValue
2
- VERSION = "1.0.0"
2
+ VERSION = "1.0.1"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: active_value
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Taiki Hiramatsu