This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Chef | |
class Node | |
class ImmutableMash | |
def to_hash | |
h = {} | |
self.each do |k,v| | |
if v.respond_to?('to_hash') | |
h[k] = v.to_hash | |
elsif v.respond_to?('each') | |
h[k] = [] |