fix with defers on failure with tor
All checks were successful
continuous-integration/drone/push Build is passing
continuous-integration/drone/tag Build is passing

This commit is contained in:
Paul 2022-03-09 00:04:23 +01:00
parent d05d283354
commit 961f83badb

View File

@ -45,12 +45,13 @@ func main() {
}
tr, dialer, dialerctx, err := network.InitTorSession()
defer dialerctx()
defer tr.Close()
if err != nil {
log.Println(err)
return
}
defer dialerctx()
defer tr.Close()
cr, err = coronafana.GetData(cfg, dialer)
if err != nil {