bulkrax 4.1.0 → 4.1.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: 7196362349b79b42a3d22ea7939383d43fbd44332184096dfbce2e37faa0504e
4
- data.tar.gz: bfdf2c501e0c7fc9bbd0ea00586c1457d46c0bc4ebc379c9767bee3bc07418fb
3
+ metadata.gz: e466ce0a1d1fe4b2c3baa9a6a5356b0138b5e7c1f2e1b88a7d17b852257f6b46
4
+ data.tar.gz: 52b585cd22870e2b4d586b3848cd48f8106f39a54341bc2aeba91a05079b9f0e
5
5
  SHA512:
6
- metadata.gz: 8095b741060d85acf813b9fcdb6794d811c5585ead33cc2a530dc0d125dd2224682514414cd352e67aed849d17774b32e9e198c5dcfa44bc002a9a65f352c657
7
- data.tar.gz: fff5bf8fed8bfd1acd314c9e5c05bbe7fe5ba457165a65856d518e27db80873b76bd39bc479e0b6fc8d06185255a61e4e108ab446f6734701c8d8de561309815
6
+ metadata.gz: cbb4169d6956f98f3b27ac143f0f16f6ac1adb86fa66a7819fad73f28d45ba5a8578b306de8d4319112a2bf1e4b4edb4aeb3b149abfa0bd840b4eb19a1aa4172
7
+ data.tar.gz: b06a77c964f82d2fa17b8cde3cff5413ceb0e9ab21eb9b7e0c299d6b42a3217308fc497474151f6b51022b7d2a48b2b2af4262a7d97941038aa6505b32e053d4
@@ -75,7 +75,7 @@ module Bulkrax
75
75
  def get_field_mapping_hash_for(key)
76
76
  return instance_variable_get("@#{key}_hash") if instance_variable_get("@#{key}_hash").present?
77
77
 
78
- mapping = importerexporter.field_mapping == [{}] ? {} : importerexporter.field_mapping
78
+ mapping = importerexporter.field_mapping.is_a?(Hash) ? importerexporter.field_mapping : {}
79
79
  instance_variable_set(
80
80
  "@#{key}_hash",
81
81
  mapping&.with_indifferent_access&.select { |_, h| h.key?(key) }
@@ -324,7 +324,7 @@ module Bulkrax
324
324
  def write_files
325
325
  require 'open-uri'
326
326
  folder_count = 0
327
- sorted_entries = sort_entries(importerexporter.entries)
327
+ sorted_entries = sort_entries(importerexporter.entries.uniq(&:identifier))
328
328
 
329
329
  sorted_entries[0..limit || total].in_groups_of(records_split_count, false) do |group|
330
330
  folder_count += 1
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Bulkrax
4
- VERSION = '4.1.0'
4
+ VERSION = '4.1.1'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bulkrax
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.1.0
4
+ version: 4.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Rob Kaufman
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-07-18 00:00:00.000000000 Z
11
+ date: 2022-07-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails