1 // Helper methods for interacting with Logger.
4 // Retrieves the map[string]interface{} stored at parent[key] if it
5 // exists, otherwise it makes it and stores it there.
6 // This is useful for logger because you may not know if a map you
7 // need has already been created.
9 parent map[string]interface{},
10 key string) (child map[string]interface{}) {
11 read, exists := parent[key]
13 child = read.(map[string]interface{})
16 child = make(map[string]interface{})