lib/fakeredis/strings.rb in fakeredis-0.1.1 vs lib/fakeredis/strings.rb in fakeredis-0.1.2

- old
+ new

@@ -52,9 +52,14 @@ def mget(*keys) @data.values_at(*keys) end + def mapped_mget(*keys) + reply = mget(*keys) + Hash[*keys.zip(reply).flatten] + end + def mset(*pairs) pairs.each_slice(2) do |pair| @data[pair[0].to_s] = pair[1].to_s end "OK"