mirror of
https://github.com/rclone/rclone.git
synced 2024-11-08 01:25:14 +01:00
15 lines
202 B
Go
15 lines
202 B
Go
//+build !go1.7
|
|
|
|
package rc
|
|
|
|
import (
|
|
"encoding/json"
|
|
"io"
|
|
)
|
|
|
|
// WriteJSON writes JSON in out to w
|
|
func WriteJSON(w io.Writer, out Params) error {
|
|
enc := json.NewEncoder(w)
|
|
return enc.Encode(out)
|
|
}
|