Fixing err return bug

This commit is contained in:
Sarah Jamie Lewis 2018-06-25 21:47:21 -07:00
parent ea2e7caf5c
commit ba196ecd0e
1 changed files with 3 additions and 0 deletions

View File

@ -88,6 +88,9 @@ func (tm *Manager) TestConnection() error {
if c != nil {
c.Close()
}
if err == nil {
return nil
}
return fmt.Errorf("could not connect to Tor Control Port %v %v", tm.controlPort, err)
}
return errors.New(proxyStatusMessage(proxyStatus))