Fix and implement supplier counters
This commit is contained in:
@@ -8,15 +8,16 @@ module Qwaiter
|
||||
end
|
||||
|
||||
def self.get(key)
|
||||
connection.get(key).to_i
|
||||
connection.get(key, quiet: true).to_i
|
||||
end
|
||||
|
||||
def self.incr(*args)
|
||||
connection.incr(*args)
|
||||
def self.incr(key, options = {})
|
||||
options[:initial] ||= 0
|
||||
connection.incr(key, options)
|
||||
end
|
||||
|
||||
def self.decr(*args)
|
||||
connection.decr(*args)
|
||||
def self.decr(key, options = {})
|
||||
connection.decr(key, options)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user