forked from jshiffer/go-xmpp
Merge pull request #110 from eaglerayp/feature/noTLS
Fix client no StartTLS & server no required
This commit is contained in:
commit
6093f50721
2
xmpp.go
2
xmpp.go
@ -487,6 +487,8 @@ func (c *Client) startTLSIfRequired(f *streamFeatures, o *Options, domain string
|
||||
case f.StartTLS == nil:
|
||||
// the server does not support STARTTLS
|
||||
return f, nil
|
||||
case !o.StartTLS && f.StartTLS.Required == nil:
|
||||
return f, nil
|
||||
case f.StartTLS.Required != nil:
|
||||
// the server requires STARTTLS.
|
||||
case !o.StartTLS:
|
||||
|
Loading…
Reference in New Issue
Block a user