redaction 0.2.0 → 0.3.0

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: 8c7c1ab9e4c83779e70bd6cc332671fd69a007281c34b4c64ea4ce309ca1eb49
4
- data.tar.gz: b2c8ef0998df228f1062b91e6a3d4cff740071c3d41cb5082d34431254e2b446
3
+ metadata.gz: 8bc14b33dd2b915ffb1af50537fa036024284e7d25b5d684b005ccfc43912062
4
+ data.tar.gz: faee2e5e5768ac841c6b72fcf6d51fced89cbae9bb79b326751581619e624404
5
5
  SHA512:
6
- metadata.gz: 1ec8127de732264971eef233c3ee8366db0eb660e84b427901180729c0f5d7c253d227c3591c6a3ab403b1e930dbcf709935d224382dd4cdc79b2736fee9056e
7
- data.tar.gz: 0fb500148ce2f328f96d59bf0ff497bc908a6d2641e363d9fa5e7f9d6301cc0c2a1ba429025c6986c91103d0ae70036b11198c20225921cb9b5628389ab1c853
6
+ metadata.gz: 2dfaf94ee151f629d748d83ce8c31d1892cefbccf686e3fab4df66faafc0b6b31cc59d8a00f8cceb4aaf20b57b2ce19a609c10da1a7194bcfc91f20a6c289614
7
+ data.tar.gz: d881259bd6d4193c175dbbf8bf81d2c3d5defd015c98b33d94685e03f83f5da1c05c7fbf19c4dbeba95018251842a16316b2cdaea554735e1deaf5c7fc69dfea
@@ -12,6 +12,7 @@ module Redaction
12
12
  options = config.redaction
13
13
 
14
14
  options.email_domain = options.email_domain
15
+ options.progress_bar = options.key?(:progress_bar) ? options.progress_bar : true
15
16
 
16
17
  ActiveSupport.on_load(:active_record) do
17
18
  include Redaction::Redactable
@@ -14,11 +14,11 @@ module Redaction
14
14
  models_to_redact.each do |model|
15
15
  next if model.redacted_attributes.empty?
16
16
 
17
- model_progress = progress_bar(model.name, model.count)
17
+ model_progress = progress_bar(model.name, model.count) if Redaction.config.progress_bar
18
18
 
19
19
  model.all.unscoped.find_each do |record|
20
20
  record.redact!
21
- model_progress.increment
21
+ model_progress.increment if Redaction.config.progress_bar
22
22
  end
23
23
  end
24
24
  end
@@ -1,3 +1,3 @@
1
1
  module Redaction
2
- VERSION = "0.2.0"
2
+ VERSION = "0.3.0"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: redaction
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Drew Bragg
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-05-06 00:00:00.000000000 Z
11
+ date: 2022-05-20 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -30,28 +30,28 @@ dependencies:
30
30
  requirements:
31
31
  - - ">="
32
32
  - !ruby/object:Gem::Version
33
- version: '0'
33
+ version: 2.20.0
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - ">="
39
39
  - !ruby/object:Gem::Version
40
- version: '0'
40
+ version: 2.20.0
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: ruby-progressbar
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
45
  - - ">="
46
46
  - !ruby/object:Gem::Version
47
- version: '0'
47
+ version: 1.11.0
48
48
  type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
52
  - - ">="
53
53
  - !ruby/object:Gem::Version
54
- version: '0'
54
+ version: 1.11.0
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: standard
57
57
  requirement: !ruby/object:Gem::Requirement