switchman 2.0.0 → 2.0.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: 7cec081d77daa09b754a98ce7bc335198b2dfbdbcd093df492a43803ff7a2742
4
- data.tar.gz: d93576725471024b24c4622d33e0eff9c1b61498b6c037e624d9b6ff8c78a442
3
+ metadata.gz: 0d6fc62ea8d63155621448b9dc70e5aab0bfa3e15b766ad6bc8b7282e124933b
4
+ data.tar.gz: 210c939e4c6a5c1c4b340e81c91fa68c0e019adeabf7dd0500f42eaa3605ad1e
5
5
  SHA512:
6
- metadata.gz: 6d4c7b1e82460fbdfda1659fc09379583c5e63ecc21d412466563a62c42679db864f8f09c2eaa2bed17b53216c64d18c42caabec76291f25e00bfc1e6a2499a1
7
- data.tar.gz: e52baf68ce2301dfa26abffd423e9855c875232871539fea59ae88ffd8f3b355299cb4c0bb60e32bf90555e7e935d2f73954ec01919cab16993bee73b39e56b6
6
+ metadata.gz: 780cc1c19606c00ecfb8df648a3f2d1e9744f375ff0a1e7793482108f81221f313254e16873db977af14e19adb0cb3d1bd9af3318c15c92ba3e54e01a91eb072
7
+ data.tar.gz: fe688c62be4f0b5e36279b93925377d3165d238a19c37124d90d464b9eac08691f2b8f0f550e56ccf5dd092cd872a3bf1ec23780fc719b8b2cf3a62539a06113
@@ -40,7 +40,7 @@ module Switchman
40
40
  def default(reload_deprecated = false, reload: false, with_fallback: false)
41
41
  if reload_deprecated
42
42
  reload = reload_deprecated
43
- ActiveSupport::Deprecation.warn("positional reload parameter to Switchman::Shard.default is deprecated; use `reload: true`")
43
+ ::ActiveSupport::Deprecation.warn("positional reload parameter to Switchman::Shard.default is deprecated; use `reload: true`")
44
44
  end
45
45
  if !@default || reload
46
46
  # Have to create a dummy object so that several key methods still work
@@ -128,9 +128,9 @@ module Switchman
128
128
  result
129
129
  end
130
130
 
131
- def transaction(options={}, &block)
131
+ def transaction(**kwargs, &block)
132
132
  shard.activate(self.class.shard_category) do
133
- self.class.transaction(options, &block)
133
+ self.class.transaction(**kwargs, &block)
134
134
  end
135
135
  end
136
136
 
@@ -2,7 +2,7 @@ module Switchman
2
2
  module ActiveRecord
3
3
  module Persistence
4
4
  # touch reads the id attribute directly, so it's not relative to the current shard
5
- def touch(*)
5
+ def touch(*, **)
6
6
  shard.activate(self.class.shard_category) { super }
7
7
  end
8
8
 
@@ -15,12 +15,12 @@ module Switchman
15
15
  end
16
16
 
17
17
  module RedisCacheStore
18
- def clear(options = {})
18
+ def clear(namespace: nil, **)
19
19
  # RedisCacheStore tries to be smart and only clear the cache under your namespace, if you have one set
20
20
  # unfortunately, it uses the keys command, which is extraordinarily inefficient in a large redis instance
21
21
  # fortunately, we can assume we control the entire instance, because we set up the namespacing, so just
22
22
  # always unset it temporarily for clear calls
23
- options[:namespace] = nil
23
+ namespace = nil
24
24
  super
25
25
  end
26
26
  end
@@ -1,3 +1,3 @@
1
1
  module Switchman
2
- VERSION = "2.0.0"
2
+ VERSION = "2.0.1"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: switchman
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.0
4
+ version: 2.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Cody Cutrer
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2020-10-05 00:00:00.000000000 Z
13
+ date: 2020-10-13 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: railties