From 5b5e892d4bdce2f953a93454edd4fb76db912200 Mon Sep 17 00:00:00 2001 From: James Bardin Date: Fri, 16 Dec 2016 09:35:58 -0500 Subject: [PATCH] fix flatmap.Expand flatmap.Expand was adding `%` as a value in nested maps. Removing that allows us properly expand objects other than a simple map. --- flatmap/expand.go | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/flatmap/expand.go b/flatmap/expand.go index 2b689281e..b2072a62f 100644 --- a/flatmap/expand.go +++ b/flatmap/expand.go @@ -66,7 +66,10 @@ func expandMap(m map[string]string, prefix string) map[string]interface{} { continue } - // It contains a period, so it is a more complex structure + // skip the map count value + if key == "%" { + continue + } result[key] = Expand(m, k[:len(prefix)+len(key)]) }