1
0
mirror of https://github.com/taigrr/yq synced 2025-01-18 04:53:17 -08:00

fix tests

This commit is contained in:
Morgan Bazalgette
2020-10-07 19:22:45 +02:00
committed by Mike Farah
parent a125495eec
commit bb9cb0c60e
3 changed files with 27 additions and 23 deletions

View File

@@ -166,7 +166,9 @@ func (o orderedMap) MarshalJSON() ([]byte, error) {
return nil, err
}
buf.WriteByte(':')
enc.Encode(el.V)
if err := enc.Encode(el.V); err != nil {
return nil, err
}
if idx != len(o.kv)-1 {
buf.WriteByte(',')
}