active_orm 4.0.0 → 4.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
  SHA1:
3
- metadata.gz: f553533ee1d9e00017974e9be0f066242baaf401
4
- data.tar.gz: 8dc77ee230e832e299ef3bf08dba9c8cea08be5b
3
+ metadata.gz: 4deb75501ba7da047700c92bb852e9a4de02e398
4
+ data.tar.gz: 679eec5ed195d5a9c20760d90f59d8b7b74e350b
5
5
  SHA512:
6
- metadata.gz: 060aeaf9aa0a1bc68ab5646e39379aaa06a838c6b18b855471e958fa01b04bf1c551583c4e3d94c68c0aaa5336d79d058ecfb3f1771551d358168098f53186f3
7
- data.tar.gz: be4c7ba86630e1c45d9cff37d83d10561cd59beae5745419f2d4661eb43bf287d07590c774e85b84d89ad75dfa41127ba4828b89b67f75aef531e7f652f78d62
6
+ metadata.gz: 907c5dc02a065cd7c68326593eb9b796389c7073ea43e554c72361922a66f12362fe77ffa3a366e033436b9516e69a560f2f58fef3ebe14cd6d10aff3ea425f5
7
+ data.tar.gz: a915205ad07aa5451f99cbfd71b0f527bde1fc4d444586b9aac33727e87631cad8142b0b6153d07c1cf65ca62eac9704c8142c3b61b5964908244315790cd258
@@ -88,8 +88,8 @@ class ActiveOrm::Redis::Connection < ActiveOrm::Redis
88
88
  client.time
89
89
  end
90
90
 
91
- def self.with_reconnect(val = true, &block)
92
- client.with_reconnect(val, &block)
91
+ def self.with_reconnect(&block)
92
+ client.with_reconnect(true, &block)
93
93
  end
94
94
 
95
95
  def self.without_reconnect(&block)
@@ -51,7 +51,7 @@ class ActiveOrm::Redis::Hash < ActiveOrm::Redis
51
51
  end
52
52
 
53
53
  def self.create_each(key, *args)
54
- client.hmset(normalize_key(key), *args)
54
+ client.hmset(normalize_key(key), args)
55
55
  end
56
56
 
57
57
  def self.increment(key, field, value)
@@ -65,7 +65,7 @@ class ActiveOrm::Redis::Hash < ActiveOrm::Redis
65
65
  end
66
66
 
67
67
  def self.destroy(key, *args)
68
- client.hdel(normalize_key(key), *args)
68
+ client.hdel(normalize_key(key), args)
69
69
  end
70
70
 
71
71
  def self.scan(key, cursor, opts = {})
@@ -22,14 +22,12 @@ class ActiveOrm::Redis::List < ActiveOrm::Redis
22
22
 
23
23
  def self.between(key, start = 1, finish = 0)
24
24
  value = client.lrange(normalize_key(key), (start - 1), (finish - 1))
25
- value = metatransform(value)
26
- value
25
+ metatransform(value)
27
26
  end
28
27
 
29
28
  def self.all(key)
30
29
  value = client.lrange(normalize_key(key), 0, -1)
31
- value = metatransform(value)
32
- value
30
+ metatransform(value)
33
31
  end
34
32
 
35
33
  def self.count(key)
@@ -2,32 +2,27 @@ class ActiveOrm::Redis::Set < ActiveOrm::Redis
2
2
 
3
3
  def self.find(key)
4
4
  value = client.smembers(normalize_key(key))
5
- value = metatransform(value)
6
- value
5
+ metatransform(value)
7
6
  end
8
7
 
9
8
  def self.combine(*args)
10
9
  value = client.sunion(*args)
11
- value = metatransform(value)
12
- value
10
+ metatransform(value)
13
11
  end
14
12
 
15
13
  def self.difference(*args)
16
14
  value = client.sdiff(*args)
17
- value = metatransform(value)
18
- value
15
+ metatransform(value)
19
16
  end
20
17
 
21
18
  def self.intersection(key, *args)
22
19
  value = client.sinter(normalize_key(key), *args)
23
- value = metatransform(value)
24
- value
20
+ metatransform(value)
25
21
  end
26
22
 
27
23
  def self.sample(key, value = 1)
28
24
  value = client.srandmember(normalize_key(key), value)
29
- value = metatransform(value)
30
- value
25
+ metatransform(value)
31
26
  end
32
27
 
33
28
  def self.value?(key, value)
@@ -43,7 +38,7 @@ class ActiveOrm::Redis::Set < ActiveOrm::Redis
43
38
  end
44
39
 
45
40
  def self.create_combination(key, *args)
46
- client.sunionstore(normalize_key(key), *args)
41
+ client.sunionstore(normalize_key(key), args)
47
42
  end
48
43
 
49
44
  def self.create_difference(key, *args)
@@ -51,7 +46,7 @@ class ActiveOrm::Redis::Set < ActiveOrm::Redis
51
46
  end
52
47
 
53
48
  def self.create_intersection(key, *args)
54
- client.sinterstore(normalize_key(key), *args)
49
+ client.sinterstore(normalize_key(key), args)
55
50
  end
56
51
 
57
52
  def self.move(key, destination, value)
@@ -1,3 +1,3 @@
1
1
  module ActiveOrm
2
- VERSION = '4.0.0'.freeze
2
+ VERSION = '4.0.1'.freeze
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: active_orm
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.0.0
4
+ version: 4.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Juan Gomez