process_settings 0.10.4 → 0.10.5

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: 7210e6038a6c4b1b401ce316ecac6b94c01eff7d4ff620a6bc37d048be39ae82
4
- data.tar.gz: d2fa6a054c3d78c1cecc8dea04e4776c868ce20183da9906fe2414e7e98c746c
3
+ metadata.gz: 22513a938b872f9e3366d445d4c121aafd965c32bec9b937f9b2abe41ff73722
4
+ data.tar.gz: 4e352a2f5a80c19fd171810612b411762372aec422464f684cbcfe71d5d27602
5
5
  SHA512:
6
- metadata.gz: 634936b6180cd1c1d146d7cc458ae8e3ed6597a4ab25b7ad71301099334da69a3ece6d4ebdfe2451d3c54696c2b8a2caeafb3847854afa6a6355a74a19c40117
7
- data.tar.gz: 9132c9edd9f14a5140b437ac148f5c0351f519223cab7466c59b45d0554353d993af5d9a22d1e797fabe0bacf08c32a54c22b48653e27abb77dd34301197be4b
6
+ metadata.gz: ac2cf3d580dd5c27c4bed2a10a59024d886bcfecd2cae4a2b39ddc3e34b78a82f41e01323bc0732144c4bd2823c1e379c2bd218ebf34cf4dc2b1a992d9bf9b20
7
+ data.tar.gz: 97b556d773340f019947a3c623faea53086274a8ff03b62b61583c757e3d7228acb0d1b800ad21076831648238dcca008f7a0cf939ade944d33fc3832b78828d
@@ -22,14 +22,14 @@ module ProcessSettings
22
22
  raise ArgumentError, "Invalid monitor of type #{monitor.class.name} provided. Must be of type ProcessSettings::AbstractMonitor"
23
23
  end
24
24
 
25
- @instance = monitor
25
+ Monitor.instance = monitor
26
26
  end
27
27
 
28
28
  # Getter method for retrieving the current monitor instance being used by ProcessSettings
29
29
  #
30
30
  # @return [ProcessSettings::AbstractMonitor]
31
31
  def instance
32
- @instance ||= lazy_create_instance
32
+ Monitor.instance
33
33
  end
34
34
 
35
35
  # This is the main entry point for looking up settings in the process.
@@ -56,12 +56,5 @@ module ProcessSettings
56
56
  def [](*path, dynamic_context: {}, required: true)
57
57
  instance[*path, dynamic_context: dynamic_context, required: required]
58
58
  end
59
-
60
- private
61
-
62
- def lazy_create_instance
63
- ActiveSupport::Deprecation.warn("lazy creation of Monitor instance is deprecated and will be removed from ProcessSettings 1.0")
64
- Monitor.instance
65
- end
66
59
  end
67
60
  end
@@ -31,11 +31,11 @@ module ProcessSettings
31
31
  end
32
32
 
33
33
  def instance
34
- ActiveSupport::Deprecation.warn("ProcessSettings::Monitor.instance is deprecated and will be removed in v1.0. Use ProcessSettings.instance instead.")
35
34
  @instance ||= default_instance
36
35
  end
37
36
 
38
37
  def default_instance
38
+ ActiveSupport::Deprecation.warn("`ProcessSettings::Monitor.instance` is deprecated and will be removed in v1.0. Assign a `FileMonitor` object to `ProcessSettings.instance` instead.")
39
39
  @default_instance ||= new_from_settings
40
40
  end
41
41
 
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module ProcessSettings
4
- VERSION = '0.10.4'
4
+ VERSION = '0.10.5'
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: process_settings
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.10.4
4
+ version: 0.10.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Invoca