Redistat::Summary.update_all returns nil instead

of false if supplied stats hash is empty
This commit is contained in:
2010-07-24 11:16:54 +03:00
parent a07865cd37
commit a260faafa4

View File

@@ -6,7 +6,7 @@ module Redistat
def self.update_all(key, stats = {}, depth_limit = nil)
stats ||= {}
depth_limit ||= key.depth
return false if stats.size == 0
return nil if stats.size == 0
depths.each do |depth|
update(key, stats, depth)
break if depth == depth_limit