Skip to content

Commit

Permalink
Fix: insensitiviseMaps() made recursive
Browse files Browse the repository at this point in the history
So that nested keys are lowercased
  • Loading branch information
benoitmasson committed Jul 16, 2016
1 parent 639fa92 commit bf1de71
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions util.go
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,10 @@ func insensitiviseMap(m map[string]interface{}) {
if key != lower {
delete(m, key)
m[lower] = val
if m2, ok := val.(map[string]interface{}); ok {
// nested map: recursively insensitivise
insensitiviseMap(m2)
}
}
}
}
Expand Down

0 comments on commit bf1de71

Please sign in to comment.