flexirest 1.9.14 → 1.9.15

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: e675234b5624a923906ecea0ed2f1cdf47230e2bef5f35fbde9731da4bdae062
4
- data.tar.gz: '0237757812519f5b82eb311608b00414cdef1d935feecb462c330e998f960158'
3
+ metadata.gz: 9109fa6e8a984fd09fc43604d7908893d1039c5f36ddbf610f39886ec2ca051d
4
+ data.tar.gz: dbcb5e768a3562effe9f2169f85e2ccb9f26c4de5cb4d176e243dbe6fbe35e9a
5
5
  SHA512:
6
- metadata.gz: 9ca1b058118cd12b4ba659332acb5b8cde5e476c0f786b46d803f385c8b59f8661bf65352acca1c1f741dfa1872a510244f704815bb87fb92492c8618d64c027
7
- data.tar.gz: 7ae4402501167aa8a40c02bf446f5267106d9a6b5e50a9e89bfb68798e8ff5b4f20fe2acc9bd9f80cd2a5372a49f9db388fd94bfe90af516a1643c1f97d55749
6
+ metadata.gz: 81c0b923e2463e633bbf6485a8e32ea1ea6bc4988f028ffcb4fb662b8e8000d1d6e8b8c7004317805eeebb4245fb50fc6b2f91dee3ab75f0f2b20370b0013e3d
7
+ data.tar.gz: a2f56d7e3c5af7e72c4ae63b98984705e548c9ff626d677347786b4c35750058400458cddeee3ff5e602e2b8df57b46caba4650270620b7fd332247ff7712c0c
data/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # Changelog
2
2
 
3
+ ## 1.9.15
4
+
5
+ Bugfix:
6
+
7
+ - Fix not marking unchanged attributes as dirty (thanks to Khairi Adnan for the bug report).
8
+
3
9
  ## 1.9.14
4
10
 
5
11
  Bugfix:
@@ -189,7 +189,7 @@ module Flexirest
189
189
  old_value = @dirty_attributes[key.to_sym]
190
190
  old_value = @attributes[key.to_sym] unless old_value
191
191
  old_value = old_value[0] if old_value and old_value.is_a? Array
192
- @dirty_attributes[key.to_sym] = [old_value, value]
192
+ @dirty_attributes[key.to_sym] = [old_value, value] if old_value != value
193
193
  @attributes[key.to_sym] = value
194
194
  end
195
195
 
@@ -1,3 +1,3 @@
1
1
  module Flexirest
2
- VERSION = "1.9.14"
2
+ VERSION = "1.9.15"
3
3
  end
@@ -126,6 +126,13 @@ describe Flexirest::BaseWithoutValidation do
126
126
  expect(client).to be_dirty
127
127
  end
128
128
 
129
+ it "should not mark attributes that don't change as dirty" do
130
+ client = EmptyExample.new(test: "Foo")
131
+ client._clean!
132
+ client.test = client.test
133
+ expect(client).to_not be_dirty
134
+ end
135
+
129
136
  it "should store attribute set using []= array notation and mark them as dirty" do
130
137
  client = EmptyExample.new()
131
138
  client["test"] = "Something"
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: flexirest
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.9.14
4
+ version: 1.9.15
5
5
  platform: ruby
6
6
  authors:
7
7
  - Andy Jeffries
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-04-02 00:00:00.000000000 Z
11
+ date: 2020-05-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -364,7 +364,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
364
364
  - !ruby/object:Gem::Version
365
365
  version: '0'
366
366
  requirements: []
367
- rubygems_version: 3.0.6
367
+ rubygems_version: 3.1.2
368
368
  signing_key:
369
369
  specification_version: 4
370
370
  summary: This gem is for accessing REST services in a flexible way. ActiveResource