data_cleansing 1.0.3 → 1.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/data_cleansing/cleanse.rb +8 -7
- data/lib/data_cleansing/version.rb +1 -1
- data/test/test_db.sqlite3 +0 -0
- 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: 55e2691c1853610f0a8922a7af4c5f26dca80e5ed01f62d59f44f5b84134951f
|
4
|
+
data.tar.gz: 2c159c37959eaa59aee8529756986df8d4cce41092d6262b38c4a8d5e1d312d7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e926a662a1dc25354967ef76cd0bcfee1b0126b9bab03e4fee0bee672b9a7419f134297b4188faf9e451278fec7ecbc365a620b3c7eaf0ad7a01c242467afa0c
|
7
|
+
data.tar.gz: 8713022f965550e559b9e5201eab36969caf63430643caa7b4459523d08b2bfb695a8a2aabb660751ad4e13c3f688b8f16fb8353b85d95dda1e2df163b9dc488
|
@@ -166,13 +166,14 @@ module DataCleansing
|
|
166
166
|
if attrs.include?(:all) && defined?(ActiveRecord) && respond_to?(:attributes)
|
167
167
|
attrs = attributes.keys.collect { |i| i.to_sym }
|
168
168
|
attrs.delete(:id)
|
169
|
-
|
170
|
-
|
171
|
-
|
172
|
-
|
173
|
-
|
174
|
-
|
175
|
-
|
169
|
+
if ActiveRecord.version < Gem::Version.new("7.0.0")
|
170
|
+
# Replace any encrypted attributes with their non-encrypted versions if any
|
171
|
+
if defined?(SymmetricEncryption) && self.class.respond_to?(:encrypted_attributes)
|
172
|
+
self.class.encrypted_attributes.each_pair do |clear, encrypted|
|
173
|
+
if attrs.include?(encrypted.to_sym)
|
174
|
+
attrs.delete(encrypted.to_sym)
|
175
|
+
attrs << clear.to_sym
|
176
|
+
end
|
176
177
|
end
|
177
178
|
end
|
178
179
|
end
|
data/test/test_db.sqlite3
CHANGED
Binary file
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: data_cleansing
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0
|
4
|
+
version: 1.1.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Reid Morrison
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2024-09-06 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: concurrent-ruby
|
@@ -71,14 +71,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
71
71
|
requirements:
|
72
72
|
- - ">="
|
73
73
|
- !ruby/object:Gem::Version
|
74
|
-
version: '2.
|
74
|
+
version: '2.7'
|
75
75
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
76
76
|
requirements:
|
77
77
|
- - ">="
|
78
78
|
- !ruby/object:Gem::Version
|
79
79
|
version: '0'
|
80
80
|
requirements: []
|
81
|
-
rubygems_version: 3.
|
81
|
+
rubygems_version: 3.5.3
|
82
82
|
signing_key:
|
83
83
|
specification_version: 4
|
84
84
|
summary: Data Cleansing framework for Ruby, Rails, and Mongoid.
|