This fixes services networks list to be ignored when loading.
Signed-off-by: Vincent Demeester <vincent@sbr.pm>
| ... | ... |
@@ -132,7 +132,7 @@ github.com/flynn-archive/go-shlex 3f9db97f856818214da2e1057f8ad84803971cff |
| 132 | 132 |
github.com/docker/go-metrics 86138d05f285fd9737a99bee2d9be30866b59d72 |
| 133 | 133 |
|
| 134 | 134 |
# composefile |
| 135 |
-github.com/aanand/compose-file a70cb6ea5c403c383b5117dcd1dea78880a47824 |
|
| 135 |
+github.com/aanand/compose-file a3e58764f50597b6217fec07e9bff7225c4a1719 |
|
| 136 | 136 |
github.com/mitchellh/mapstructure f3009df150dadf309fdee4a54ed65c124afad715 |
| 137 | 137 |
github.com/xeipuuv/gojsonpointer e0fe6f68307607d540ed8eac07a342c33fa1b54a |
| 138 | 138 |
github.com/xeipuuv/gojsonreference e02fc20de94c78484cd5ffb007f8af96be030a45 |
| ... | ... |
@@ -515,13 +515,12 @@ func toYAMLName(name string) string {
|
| 515 | 515 |
} |
| 516 | 516 |
|
| 517 | 517 |
func loadListOrStructMap(value interface{}, target reflect.Type) (interface{}, error) {
|
| 518 |
- mapValue := reflect.MakeMap(target) |
|
| 519 |
- |
|
| 520 | 518 |
if list, ok := value.([]interface{}); ok {
|
| 519 |
+ mapValue := map[interface{}]interface{}{}
|
|
| 521 | 520 |
for _, name := range list {
|
| 522 |
- mapValue.SetMapIndex(reflect.ValueOf(name), reflect.ValueOf(nil)) |
|
| 521 |
+ mapValue[name] = nil |
|
| 523 | 522 |
} |
| 524 |
- return mapValue.Interface(), nil |
|
| 523 |
+ return mapValue, nil |
|
| 525 | 524 |
} |
| 526 | 525 |
|
| 527 | 526 |
return value, nil |