lib/aws/cfn/compiler/mixins/compile.rb in aws-cfn-compiler-0.9.18 vs lib/aws/cfn/compiler/mixins/compile.rb in aws-cfn-compiler-0.9.19
- old
+ new
@@ -185,20 +185,23 @@
newparent = key
elsif @all_sections.include? parent
newparent = key
end
if %w{Ref}.include? key
- h = { hash[key] => [type,newparent] }
+ # h = { hash[key] => [type,newparent] }
+ h[hash[key]] = [type,newparent]
elsif 'Fn::GetAtt' == key
- h = { hash[key].first => [type,newparent] }
+ # h = { hash[key].first => [type,newparent] }
+ h[hash[key].first] = [type,newparent]
elsif 'DependsOn' == key
if hash[key].is_a?(Array)
- h = {}
+ # h = {}
hash[key].map { |dep|
h[dep] = [type,newparent]
}
else
- h = { hash[key] => [type,newparent] }
+ # h = { hash[key] => [type,newparent] }
+ h[hash[key]] = [type,newparent]
end
else
a = find_refs(hash[key],type,newparent)
h = merge(h, a, *[type,newparent])
end