diff options
author | Patrick Connolly <patrick.c.connolly@gmail.com> | 2018-12-02 02:55:35 +0800 |
---|---|---|
committer | Wim <wim@42.be> | 2018-12-01 19:55:35 +0100 |
commit | e538a4d30459e9da1a021400b5de85894b4efabc (patch) | |
tree | ead4f82d5459fe0d3465f7e3656243cd613c07a6 /vendor/github.com/nlopes/slack/websocket.go | |
parent | f94c2b40a3e8eb45054bda1b71eb6fd3f9bc9e6d (diff) | |
download | matterbridge-msglm-e538a4d30459e9da1a021400b5de85894b4efabc.tar.gz matterbridge-msglm-e538a4d30459e9da1a021400b5de85894b4efabc.tar.bz2 matterbridge-msglm-e538a4d30459e9da1a021400b5de85894b4efabc.zip |
Update nlopes/slack to 4.1-dev (#595)
Diffstat (limited to 'vendor/github.com/nlopes/slack/websocket.go')
-rw-r--r-- | vendor/github.com/nlopes/slack/websocket.go | 19 |
1 files changed, 6 insertions, 13 deletions
diff --git a/vendor/github.com/nlopes/slack/websocket.go b/vendor/github.com/nlopes/slack/websocket.go index 242acf40..ec810a9b 100644 --- a/vendor/github.com/nlopes/slack/websocket.go +++ b/vendor/github.com/nlopes/slack/websocket.go @@ -3,6 +3,7 @@ package slack import ( "encoding/json" "errors" + "net/url" "sync" "time" @@ -20,6 +21,9 @@ const ( // // Create this element with Client's NewRTM() or NewRTMWithOptions(*RTMOptions) type RTM struct { + // Client is the main API, embedded + Client + idGen IDGenerator pingInterval time.Duration pingDeadman *time.Timer @@ -35,8 +39,6 @@ type RTM struct { wasIntentional bool isConnected bool - // Client is the main API, embedded - Client websocketURL string // UserDetails upon connection @@ -53,18 +55,9 @@ type RTM struct { // mu is mutex used to prevent RTM connection race conditions mu *sync.Mutex -} -// RTMOptions allows configuration of various options available for RTM messaging -// -// This structure will evolve in time so please make sure you are always using the -// named keys for every entry available as per Go 1 compatibility promise adding fields -// to this structure should not be considered a breaking change. -type RTMOptions struct { - // UseRTMStart set to true in order to use rtm.start or false to use rtm.connect - // As of 11th July 2017 you should prefer setting this to false, see: - // https://api.slack.com/changelog/2017-04-start-using-rtm-connect-and-stop-using-rtm-start - UseRTMStart bool + // connParams is a map of flags for connection parameters. + connParams url.Values } // Disconnect and wait, blocking until a successful disconnection. |