Describe the bug
Unchecked error when reading all data from reader in decodePart() function at fetcher/fetcher.go:138. The result is assigned to _, _ which silently ignores potential read failures.
To reproduce
- Trigger decodePart() with failing reader
- Error is silently ignored
- Partial or corrupt data may be returned
Expected behavior
Should check error and return it to caller
Matcha version
master branch
OS
All
Additional context
File: fetcher/fetcher.go line 138
Pattern: body, _ := ioutil.ReadAll(reader) with ignored error
Describe the bug
Unchecked error when reading all data from reader in decodePart() function at fetcher/fetcher.go:138. The result is assigned to _, _ which silently ignores potential read failures.
To reproduce
Expected behavior
Should check error and return it to caller
Matcha version
master branch
OS
All
Additional context
File: fetcher/fetcher.go line 138
Pattern: body, _ := ioutil.ReadAll(reader) with ignored error