active_form_objects 2.1.4 → 2.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/dsl/error_handling.rb +2 -3
  3. metadata +3 -3
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: e8035dcb27f78b8e96f423efa20368bf9a458a10254cf11daac46ac5da94f2e5
4
- data.tar.gz: 8547c9553340dcc67451b6f0a5eddfe21db24ebeddcd5064f1627344f6070ce6
3
+ metadata.gz: ec2115a7e0927fc58e7bd8ad1b0013d082765b48442b7b3fb75ace036218f622
4
+ data.tar.gz: 4e36c456697a2552a2637e4cdc17f8ff9ddd0137f3b2b52d9b44ae2f0fa4d5a3
5
5
  SHA512:
6
- metadata.gz: '08eecf07d908b7940c5611beb5676e629ddc6761bea108fca62689a90b2ec614cc6cfe3f2e65f0bb6f4544fc8b5fa7ff77986ff51658c8cf21969a4aa4a824d5'
7
- data.tar.gz: 4fab25d2fa5c139d5db542dc14bdc52c190ea4fad92c76cdbe985215eeb2333b79dc443e85f19fc3a77c2084e40e0343ad1e487ee569866dcea563ef9b36894f
6
+ metadata.gz: 5082b7dff3c3412f59057ecfe7f733c308a54560c12d55f0313737f928e2ae73bc4cc2eaacde782223f5e76823fa47430c3530ade6d9f24d3acc7a5b44ebecec
7
+ data.tar.gz: 5c49aadd223f7763ee6a10aa42f66c5ba6c00c19f0d11b0df98fb7b61b9d9d74a96c766a7d177526e345da234cb4d667f36c4a3803329134d262d6f89b558642
@@ -6,9 +6,8 @@ module Dsl
6
6
  record = (e.try(:record) || e.model)
7
7
  initial_messages = record.errors.messages.as_json
8
8
  record.errors.clear
9
- initial_messages.each do |i|
10
- record.errors.add(form, i)
11
- end
9
+ record.errors.messages[form] = initial_messages
10
+
12
11
  raise ActiveModel::ValidationError, record
13
12
  end
14
13
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: active_form_objects
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.4
4
+ version: 2.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Michaël Villeneuve
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-11-12 00:00:00.000000000 Z
11
+ date: 2019-10-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport
@@ -142,7 +142,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
142
142
  - !ruby/object:Gem::Version
143
143
  version: '0'
144
144
  requirements: []
145
- rubygems_version: 3.1.2
145
+ rubygems_version: 3.0.1
146
146
  signing_key:
147
147
  specification_version: 4
148
148
  summary: A step toward an hexagonal Rails architecture