Skip to content
This repository has been archived by the owner on Sep 23, 2023. It is now read-only.

Commit

Permalink
save
Browse files Browse the repository at this point in the history
  • Loading branch information
AskAlexSharov committed Sep 14, 2023
1 parent 122f5bd commit df3705d
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion downloader/downloader.go
Original file line number Diff line number Diff line change
Expand Up @@ -565,7 +565,9 @@ func (d *Downloader) Stats() AggStats {
}

func (d *Downloader) Close() {
d.stopMainLoop()
if d.stopMainLoop != nil {
d.stopMainLoop()
}
d.wg.Wait()
d.torrentClient.Close()
if err := d.folder.Close(); err != nil {
Expand Down

0 comments on commit df3705d

Please sign in to comment.