summaryrefslogtreecommitdiffstats
path: root/model/audits.go
diff options
context:
space:
mode:
Diffstat (limited to 'model/audits.go')
-rw-r--r--model/audits.go9
1 files changed, 2 insertions, 7 deletions
diff --git a/model/audits.go b/model/audits.go
index e57e2a3ac..3673eb618 100644
--- a/model/audits.go
+++ b/model/audits.go
@@ -28,12 +28,7 @@ func (o Audits) ToJson() string {
}
func AuditsFromJson(data io.Reader) Audits {
- decoder := json.NewDecoder(data)
var o Audits
- err := decoder.Decode(&o)
- if err == nil {
- return o
- } else {
- return nil
- }
+ json.NewDecoder(data).Decode(&o)
+ return o
}