dynamoid 3.13.0 → 3.13.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +9 -1
- data/lib/dynamoid/dirty.rb +10 -1
- data/lib/dynamoid/version.rb +1 -1
- metadata +4 -4
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: f4d2a63b70604d568d7656adc8e0c45fd30d358d004d5f6fb1591bf5b2731ef3
|
|
4
|
+
data.tar.gz: fbd7978ace3ce520c5afc2c445008bac5cec106579212811f34d8a445a0c5152
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 39347924ec0c682f520a62ddbbf7e51613907575e096f6e525b96218f29431044e8c92d11a3e75e9bfeb2c5553cb637bea84dcedf44bf57da9fbb5e9bf78608b
|
|
7
|
+
data.tar.gz: 333c22e0d878463aa5d25c1765a2b4b379dd9cc9c8c616447d87b6cbf2b1a97cab8f339815dc77a92dbd7ca042f1cf954cf585b36c25bbeabaa7adc61aa81787
|
data/CHANGELOG.md
CHANGED
|
@@ -11,7 +11,15 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
11
11
|
### Changed
|
|
12
12
|
### Removed
|
|
13
13
|
|
|
14
|
-
## 3.13.
|
|
14
|
+
## 3.13.1
|
|
15
|
+
|
|
16
|
+
### Fixed
|
|
17
|
+
* [#1003](https://github.com/Dynamoid/dynamoid/pull/1003) Fix detecting dirty changes for `:map` fields
|
|
18
|
+
### Added
|
|
19
|
+
### Changed
|
|
20
|
+
### Removed
|
|
21
|
+
|
|
22
|
+
## 3.13.0 / 2026-03-29
|
|
15
23
|
|
|
16
24
|
### Fixed
|
|
17
25
|
* [#944](https://github.com/Dynamoid/dynamoid/pull/944) Fix `#delete` and `#destroy` methods and set `#destroyed?` properly when operations fail
|
data/lib/dynamoid/dirty.rb
CHANGED
|
@@ -303,7 +303,16 @@ module Dynamoid
|
|
|
303
303
|
value = read_attribute(name)
|
|
304
304
|
type_options = self.class.attributes[name.to_sym]
|
|
305
305
|
|
|
306
|
-
|
|
306
|
+
if self.class.attributes.dig(name.to_sym, :type) == :map && value.is_a?(Hash)
|
|
307
|
+
# A special case for the :map field type. attributes_from_database is a
|
|
308
|
+
# HashWithIndifferentAccess which has a side effect - it converts any
|
|
309
|
+
# nested Hash to HashWithIndifferentAccess as well.
|
|
310
|
+
# HashWithIndifferentAccess#== does not tolarate containing symbolized
|
|
311
|
+
# keys in an argument Hash. So if a value is a Hash and may have
|
|
312
|
+
# symbolized keys - wrap it into HashWithIndifferentAccess.
|
|
313
|
+
value_wrapped = value.with_indifferent_access
|
|
314
|
+
value_wrapped != value_from_database
|
|
315
|
+
elsif !type_options[:type].is_a?(Class) || type_options[:comparable]
|
|
307
316
|
# common case
|
|
308
317
|
value != value_from_database
|
|
309
318
|
else
|
data/lib/dynamoid/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: dynamoid
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 3.13.
|
|
4
|
+
version: 3.13.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Josh Symonds
|
|
@@ -263,10 +263,10 @@ licenses:
|
|
|
263
263
|
- MIT
|
|
264
264
|
metadata:
|
|
265
265
|
homepage_uri: http://github.com/Dynamoid/dynamoid
|
|
266
|
-
source_code_uri: https://github.com/Dynamoid/dynamoid/tree/v3.13.
|
|
267
|
-
changelog_uri: https://github.com/Dynamoid/dynamoid/blob/v3.13.
|
|
266
|
+
source_code_uri: https://github.com/Dynamoid/dynamoid/tree/v3.13.1
|
|
267
|
+
changelog_uri: https://github.com/Dynamoid/dynamoid/blob/v3.13.1/CHANGELOG.md
|
|
268
268
|
bug_tracker_uri: https://github.com/Dynamoid/dynamoid/issues
|
|
269
|
-
documentation_uri: https://www.rubydoc.info/gems/dynamoid/3.13.
|
|
269
|
+
documentation_uri: https://www.rubydoc.info/gems/dynamoid/3.13.1
|
|
270
270
|
funding_uri: https://opencollective.com/dynamoid
|
|
271
271
|
wiki_uri: https://github.com/Dynamoid/dynamoid/wiki
|
|
272
272
|
rubygems_mfa_required: 'true'
|