simple_events_redis 0.0.5 → 0.0.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +8 -8
- data/lib/events.rb +3 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
---
|
|
2
2
|
!binary "U0hBMQ==":
|
|
3
3
|
metadata.gz: !binary |-
|
|
4
|
-
|
|
4
|
+
MDNjZWRiZWFmOWZmNDM3NTE2ZmFlOTFhN2Y1Nzg3ODk2ZjlhN2VmZA==
|
|
5
5
|
data.tar.gz: !binary |-
|
|
6
|
-
|
|
6
|
+
MjgxMzkxNDgwZWQyNjZmMDhiOGE5YmUyYWNjMDcwZmRkNzE0N2YxMw==
|
|
7
7
|
!binary "U0hBNTEy":
|
|
8
8
|
metadata.gz: !binary |-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
NDViMDNkMDE0NTYyMDdkMGEwYjlkMTI4ZWU3NDhiOTIyNzI1NmMzNzM0NzYw
|
|
10
|
+
NTcxZmVmODExZTY5NzYzOTMxZTNkYmYyZmJjMTk1OWVmOTBlZmYxM2JhM2U1
|
|
11
|
+
ZWNlY2M5OTNiY2MxMzEwYWRkZTRiZmZiMWQzNGE5MTUzZGE2YzI=
|
|
12
12
|
data.tar.gz: !binary |-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
13
|
+
OGJjMDVmZDgzY2UwNGRhM2U4YjdkMDhjYjFiMTQzN2E0YjBjYTM0YjY3NzFl
|
|
14
|
+
NTExNDhmNGZlNjExYzQ2MzgyNmUwMzM2MjlmODc3ZTk5Zjc2MjQ2MjRiN2Iz
|
|
15
|
+
MzY1Mjc0MTRhYjZjNTRhMTM4NDZjYjI4YWEwN2U2MGI5MmExMjE=
|
data/lib/events.rb
CHANGED
|
@@ -200,7 +200,9 @@
|
|
|
200
200
|
# counters
|
|
201
201
|
|
|
202
202
|
def self.stat_add(event_name, n=1)
|
|
203
|
-
|
|
203
|
+
rkey = self.redis_key_stat
|
|
204
|
+
redis.hincrby rkey, event_name, n
|
|
205
|
+
redis.expire rkey, self.config(:EXPIRE_DAYS)*24*60*60
|
|
204
206
|
|
|
205
207
|
return true
|
|
206
208
|
end
|