fix(downloader): close file error

This commit is contained in:
iyear 2022-09-04 13:18:20 +08:00
parent 6bfe8c8f91
commit d81c5d072e

View File

@ -91,7 +91,7 @@ func (d *Downloader) download(ctx context.Context, item *Item) error {
f: f,
tracker: tracker,
})
if err = f.Close(); err != nil {
if err := f.Close(); err != nil {
return err
}
if err != nil {