mirror of
https://github.com/minio/minio.git
synced 2025-11-07 04:42:56 -05:00
tests: Do not allow forced type asserts (#20905)
This commit is contained in:
@@ -369,8 +369,8 @@ FLAGS:
|
||||
defer f.Close()
|
||||
r = f
|
||||
}
|
||||
if strings.HasSuffix(file, ".zip") {
|
||||
zr, err := zip.NewReader(r.(io.ReaderAt), sz)
|
||||
if ra, ok := r.(io.ReaderAt); ok && strings.HasSuffix(file, ".zip") {
|
||||
zr, err := zip.NewReader(ra, sz)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user