mirror of
https://github.com/jimeh/redistat.git
synced 2026-02-19 13:26:39 +00:00
added #parent_group method to Label and Key objects
This commit is contained in:
@@ -53,6 +53,10 @@ module Redistat
|
||||
end
|
||||
end
|
||||
|
||||
def parent_group
|
||||
@label.parent_group
|
||||
end
|
||||
|
||||
def to_s(depth = nil)
|
||||
depth ||= @options[:depth]
|
||||
key = self.prefix
|
||||
|
||||
@@ -49,5 +49,9 @@ module Redistat
|
||||
@groups.reverse!
|
||||
end
|
||||
|
||||
def parent_group
|
||||
groups[-2]
|
||||
end
|
||||
|
||||
end
|
||||
end
|
||||
Reference in New Issue
Block a user