From: antirez Date: Thu, 10 Dec 2009 18:47:12 +0000 (+0100) Subject: redis-sha1.rb utility updated X-Git-Url: https://git.saurik.com/redis.git/commitdiff_plain/5ad3c8c852de981482afb28a8c2659456b2a8b3b redis-sha1.rb utility updated --- diff --git a/utils/redis-sha1.rb b/utils/redis-sha1.rb index 6f9e045b..b240e2ca 100644 --- a/utils/redis-sha1.rb +++ b/utils/redis-sha1.rb @@ -24,6 +24,8 @@ def redisSha1(opts={}) sha1 = Digest::SHA1.hexdigest(sha1+r.list_range(k,0,-1).join("\x01")) elsif vtype == "set" sha1 = Digest::SHA1.hexdigest(sha1+r.set_members(k).to_a.sort.join("\x02")) + elsif vtype == "zset" + sha1 = Digest::SHA1.hexdigest(sha1+r.zrange(k,0,-1).join("\x01")) end } sha1