activerecord_csv_importer 0.2.1 → 0.2.2

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: 5a0968d9c3ac0956cf6bf872940850871e440ed4454d7cdf361f1ba8760e7a77
4
- data.tar.gz: 605dae0b053a3faf4472a78483f9da6270fa637b8dc3f33cbd9d3cb94aa569f3
3
+ metadata.gz: 147032026b8134252dc7ba00893ebcf36a9bbc1dde2ad6ea21c97b67a285455d
4
+ data.tar.gz: 636aae65bed064b82f1abd2c5bbadaf9522d918de104909e7fea9d01b566e6cd
5
5
  SHA512:
6
- metadata.gz: 98754a9ba0bebeb68f95b530ce9b2b87c7a6ba8b844794aa5c9758f5fe1ffe09ac428fb485da6d9f1799b27ca506f426d8ebb8fb7e5ca432d903ebfe9d648c6e
7
- data.tar.gz: 3159cc18c6e0676476ec908589051b0eb27d0e72104e7881d5fe486619f08fd6c0034db8239d3923a7d88a7dd20258f0d0a01298afa9ac4cf4074de597bdb3ee
6
+ metadata.gz: 56835d93d4e6236d214bab250778571b3cce68f59a38ef5b7bcdf989f4d39e1e3942319600ba28617d69effd5ad9aa46407f819223e02c2004e7507858f5bb8e
7
+ data.tar.gz: 7ea6072403f6697b522a0042c626f69664ec6944739cde28cc7ac9045271bb06e77b8dd5f5bf49e3db609b2ecfa83ba93ebf8ac264f0003173eb7d65dced0d15
@@ -66,9 +66,9 @@ module ActiveRecordCSVImporter
66
66
  # Error from the model mapped back to the CSV header if we can
67
67
  def build_error(model)
68
68
  Hash[
69
- model.errors.map do |attribute, errors|
70
- column_name = header.column_name_for_model_attribute(attribute)
71
- column_name ? [column_name, errors] : [attribute, errors]
69
+ model.errors.map do |e|
70
+ column_name = header.column_name_for_model_attribute(e.attribute)
71
+ column_name ? [column_name, e.type] : [e.attribute, e.type]
72
72
  end
73
73
  ]
74
74
  end
@@ -1,3 +1,3 @@
1
1
  module ActiveRecordCSVImporter
2
- VERSION = '0.2.1'.freeze
2
+ VERSION = '0.2.2'.freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: activerecord_csv_importer
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1
4
+ version: 0.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Zulfiqar Ali
8
- autorequire:
8
+ autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2019-03-14 00:00:00.000000000 Z
11
+ date: 2020-12-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: virtus
@@ -122,7 +122,7 @@ dependencies:
122
122
  - - "~>"
123
123
  - !ruby/object:Gem::Version
124
124
  version: '1.2'
125
- description:
125
+ description:
126
126
  email:
127
127
  - desheikh@gmail.com
128
128
  executables: []
@@ -157,7 +157,7 @@ homepage: https://github.com/desheikh/activerecord_csv_importer
157
157
  licenses:
158
158
  - MIT
159
159
  metadata: {}
160
- post_install_message:
160
+ post_install_message:
161
161
  rdoc_options: []
162
162
  require_paths:
163
163
  - lib
@@ -172,8 +172,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
172
172
  - !ruby/object:Gem::Version
173
173
  version: '0'
174
174
  requirements: []
175
- rubygems_version: 3.0.1
176
- signing_key:
175
+ rubygems_version: 3.0.3
176
+ signing_key:
177
177
  specification_version: 4
178
178
  summary: A modified version of CSV Import using activerecord-import
179
179
  test_files: []