Remove redundant error checks

Signed-off-by: Davor Kapsa <davor.kapsa@gmail.com>
This commit is contained in:
Davor Kapsa
2019-04-30 21:28:51 +02:00
parent bf5a424679
commit cfc36388b3
5 changed files with 6 additions and 23 deletions

View File

@@ -197,10 +197,7 @@ func onUntarJSON(r io.Reader, j interface{}) error {
if err != nil {
return err
}
if err := json.Unmarshal(b, j); err != nil {
return err
}
return nil
return json.Unmarshal(b, j)
}
func onUntarBlob(ctx context.Context, r io.Reader, store content.Ingester, size int64, ref string) (digest.Digest, error) {