robust-redis-lock 0.4.0 → 0.4.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
  SHA1:
3
- metadata.gz: ff73b4f537214a712e375526275c68be1037ea7e
4
- data.tar.gz: 50257826714c16e8cba1658f89fac74e65a9452f
3
+ metadata.gz: e5f81aecb46ec64804f60f5d67066896cbe05eb0
4
+ data.tar.gz: 7424bac609f9bf243345733935d3618ef2395ba5
5
5
  SHA512:
6
- metadata.gz: dd8d1e3474a94440fe7cde4a04c005337acdba1fa1c0b700a39e00fb03e559b76a4e941f32dca30ed6618513d47f3f9ffc8e28c4efe7ee04b7b11a01e2fb2c1d
7
- data.tar.gz: 72dd7a3174784487cca91c6bfa8dbd52621edbafc8c696ab88421c13bdeba670a5b23a8d875441574a952c747b85d616d6a553e38b750a44c1db97bb08a1fe6e
6
+ metadata.gz: 11470af19b0e99a204d705ec229bfe2a8ea01279a1cb1af904a0f9f3c605483ffcf8c5fcb58572add121c8ab1d5f039a54397faefe4a9a0d656dd3033321a0aa
7
+ data.tar.gz: a050eb216fe5a95d117ba4d0f3bb69b8265b7b6fae11f7136c36aeaa27ad1b1daa0fb094d42cf2e8e41e1825916de208218d5d7ab9a1afb754b7c41650c6c5b9
@@ -16,7 +16,8 @@ class Redis::Lock
16
16
  attr_accessor :serializer
17
17
 
18
18
  def expired(options={})
19
- self.redis.zrangebyscore(key_group_key(options), 0, Time.now.to_i).map { |key| self.new(key, options) }
19
+ redis = options[:redis] || self.redis
20
+ redis.zrangebyscore(key_group_key(options), 0, Time.now.to_i).to_a.map { |key| self.new(key, options) }
20
21
  end
21
22
 
22
23
  def key_group_key(options)
@@ -1,5 +1,5 @@
1
1
  class Redis
2
2
  class Lock
3
- VERSION = '0.4.0'
3
+ VERSION = '0.4.1'
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: robust-redis-lock
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.0
4
+ version: 0.4.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kareem Kouddous
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-12-17 00:00:00.000000000 Z
11
+ date: 2014-12-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: redis