mirror of
https://github.com/nboughton/dotfiles
synced 2024-11-22 23:51:57 +01:00
return error from json write
This commit is contained in:
parent
92c9d95cf0
commit
4700a00667
@ -19,8 +19,8 @@ type JSONOutput struct {
|
|||||||
Percentage int `json:"percentage,omitempty"`
|
Percentage int `json:"percentage,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
func (j JSONOutput) Write(o io.Writer) {
|
func (j JSONOutput) Write(o io.Writer) error {
|
||||||
json.NewEncoder(o).Encode(j)
|
return json.NewEncoder(o).Encode(j)
|
||||||
}
|
}
|
||||||
|
|
||||||
// Module wraps summary and json data
|
// Module wraps summary and json data
|
||||||
|
Loading…
Reference in New Issue
Block a user