redness 0.1.4 → 0.1.5
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/redness/red_set.rb +2 -0
- data/lib/redness/version.rb +1 -1
- metadata +15 -45
data/lib/redness/red_set.rb
CHANGED
@@ -12,6 +12,8 @@ class RedSet
|
|
12
12
|
if redis.zrank(key, member).nil?
|
13
13
|
if options[:score] and options[:score].respond_to?(:call)
|
14
14
|
score = options[:score].call.to_i
|
15
|
+
elsif options[:score] && options[:score].respond_to?(:to_i)
|
16
|
+
score = options[:score].to_i
|
15
17
|
else
|
16
18
|
score = redis.zcard(key).to_i
|
17
19
|
end
|
data/lib/redness/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: redness
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.5
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -14,11 +14,11 @@ authors:
|
|
14
14
|
autorequire:
|
15
15
|
bindir: bin
|
16
16
|
cert_chain: []
|
17
|
-
date: 2012-
|
17
|
+
date: 2012-10-25 00:00:00.000000000 Z
|
18
18
|
dependencies:
|
19
19
|
- !ruby/object:Gem::Dependency
|
20
20
|
name: json
|
21
|
-
requirement: !ruby/object:Gem::Requirement
|
21
|
+
requirement: &70238911257720 !ruby/object:Gem::Requirement
|
22
22
|
none: false
|
23
23
|
requirements:
|
24
24
|
- - ! '>='
|
@@ -26,15 +26,10 @@ dependencies:
|
|
26
26
|
version: '0'
|
27
27
|
type: :runtime
|
28
28
|
prerelease: false
|
29
|
-
version_requirements:
|
30
|
-
none: false
|
31
|
-
requirements:
|
32
|
-
- - ! '>='
|
33
|
-
- !ruby/object:Gem::Version
|
34
|
-
version: '0'
|
29
|
+
version_requirements: *70238911257720
|
35
30
|
- !ruby/object:Gem::Dependency
|
36
31
|
name: rspec
|
37
|
-
requirement: !ruby/object:Gem::Requirement
|
32
|
+
requirement: &70238911276400 !ruby/object:Gem::Requirement
|
38
33
|
none: false
|
39
34
|
requirements:
|
40
35
|
- - ! '>='
|
@@ -42,15 +37,10 @@ dependencies:
|
|
42
37
|
version: '0'
|
43
38
|
type: :runtime
|
44
39
|
prerelease: false
|
45
|
-
version_requirements:
|
46
|
-
none: false
|
47
|
-
requirements:
|
48
|
-
- - ! '>='
|
49
|
-
- !ruby/object:Gem::Version
|
50
|
-
version: '0'
|
40
|
+
version_requirements: *70238911276400
|
51
41
|
- !ruby/object:Gem::Dependency
|
52
42
|
name: redis
|
53
|
-
requirement: !ruby/object:Gem::Requirement
|
43
|
+
requirement: &70238911275520 !ruby/object:Gem::Requirement
|
54
44
|
none: false
|
55
45
|
requirements:
|
56
46
|
- - ~>
|
@@ -58,15 +48,10 @@ dependencies:
|
|
58
48
|
version: 3.0.0
|
59
49
|
type: :runtime
|
60
50
|
prerelease: false
|
61
|
-
version_requirements:
|
62
|
-
none: false
|
63
|
-
requirements:
|
64
|
-
- - ~>
|
65
|
-
- !ruby/object:Gem::Version
|
66
|
-
version: 3.0.0
|
51
|
+
version_requirements: *70238911275520
|
67
52
|
- !ruby/object:Gem::Dependency
|
68
53
|
name: activesupport
|
69
|
-
requirement: !ruby/object:Gem::Requirement
|
54
|
+
requirement: &70238911275060 !ruby/object:Gem::Requirement
|
70
55
|
none: false
|
71
56
|
requirements:
|
72
57
|
- - ! '>='
|
@@ -74,15 +59,10 @@ dependencies:
|
|
74
59
|
version: '0'
|
75
60
|
type: :runtime
|
76
61
|
prerelease: false
|
77
|
-
version_requirements:
|
78
|
-
none: false
|
79
|
-
requirements:
|
80
|
-
- - ! '>='
|
81
|
-
- !ruby/object:Gem::Version
|
82
|
-
version: '0'
|
62
|
+
version_requirements: *70238911275060
|
83
63
|
- !ruby/object:Gem::Dependency
|
84
64
|
name: timecop
|
85
|
-
requirement: !ruby/object:Gem::Requirement
|
65
|
+
requirement: &70238911274600 !ruby/object:Gem::Requirement
|
86
66
|
none: false
|
87
67
|
requirements:
|
88
68
|
- - ! '>='
|
@@ -90,15 +70,10 @@ dependencies:
|
|
90
70
|
version: '0'
|
91
71
|
type: :development
|
92
72
|
prerelease: false
|
93
|
-
version_requirements:
|
94
|
-
none: false
|
95
|
-
requirements:
|
96
|
-
- - ! '>='
|
97
|
-
- !ruby/object:Gem::Version
|
98
|
-
version: '0'
|
73
|
+
version_requirements: *70238911274600
|
99
74
|
- !ruby/object:Gem::Dependency
|
100
75
|
name: rake
|
101
|
-
requirement: !ruby/object:Gem::Requirement
|
76
|
+
requirement: &70238911274000 !ruby/object:Gem::Requirement
|
102
77
|
none: false
|
103
78
|
requirements:
|
104
79
|
- - ! '>='
|
@@ -106,12 +81,7 @@ dependencies:
|
|
106
81
|
version: '0'
|
107
82
|
type: :development
|
108
83
|
prerelease: false
|
109
|
-
version_requirements:
|
110
|
-
none: false
|
111
|
-
requirements:
|
112
|
-
- - ! '>='
|
113
|
-
- !ruby/object:Gem::Version
|
114
|
-
version: '0'
|
84
|
+
version_requirements: *70238911274000
|
115
85
|
description: Helpful Ruby classes for improved Redis data structures
|
116
86
|
email: dev@howaboutwe.com
|
117
87
|
executables: []
|
@@ -172,7 +142,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
172
142
|
version: '0'
|
173
143
|
requirements: []
|
174
144
|
rubyforge_project:
|
175
|
-
rubygems_version: 1.8.
|
145
|
+
rubygems_version: 1.8.15
|
176
146
|
signing_key:
|
177
147
|
specification_version: 3
|
178
148
|
summary: Helpful Ruby classes for improved Redis data structures
|