Commit f5bf7e3e authored by antirez's avatar antirez
Browse files

RubyRedis info postprocessor rewritten in a more functional way

parent fc9aeaea
...@@ -31,8 +31,7 @@ class RedisClient ...@@ -31,8 +31,7 @@ class RedisClient
"info" => lambda{|r| "info" => lambda{|r|
info = {} info = {}
r.each_line {|kv| r.each_line {|kv|
k,v = kv.split(':', 2) k,v = kv.split(":",2).map{|x| x.chomp}
k,v = k.chomp, v = v.chomp
info[k.to_sym] = v info[k.to_sym] = v
} }
info info
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment