aboutsummaryrefslogtreecommitdiff
path: root/vendor/github.com/bwmarrin/discordgo/discord.go
diff options
context:
space:
mode:
authorJordan <me@jordan.im>2022-09-30 11:52:44 -0700
committerJordan <me@jordan.im>2022-09-30 11:52:44 -0700
commit0192a4e3f1c90df255e44831a579d9b0f611a543 (patch)
tree52c6bfa35b5491560af253a5e5ba90ed8a729871 /vendor/github.com/bwmarrin/discordgo/discord.go
parent66bfe530b4fd5cb9755337ce718df26ee81f1b77 (diff)
downloadkeep-0192a4e3f1c90df255e44831a579d9b0f611a543.tar.gz
keep-0192a4e3f1c90df255e44831a579d9b0f611a543.zip
go.mod: bump discordgo, go-sqlite3, x/net
Diffstat (limited to 'vendor/github.com/bwmarrin/discordgo/discord.go')
-rw-r--r--vendor/github.com/bwmarrin/discordgo/discord.go9
1 files changed, 6 insertions, 3 deletions
diff --git a/vendor/github.com/bwmarrin/discordgo/discord.go b/vendor/github.com/bwmarrin/discordgo/discord.go
index 74f4190..fc7b6d7 100644
--- a/vendor/github.com/bwmarrin/discordgo/discord.go
+++ b/vendor/github.com/bwmarrin/discordgo/discord.go
@@ -17,10 +17,12 @@ import (
"net/http"
"runtime"
"time"
+
+ "github.com/gorilla/websocket"
)
// VERSION of DiscordGo, follows Semantic Versioning. (http://semver.org/)
-const VERSION = "0.24.0"
+const VERSION = "0.26.1"
// New creates a new Discord session with provided token.
// If the token is for a bot, it must be prefixed with "Bot "
@@ -36,20 +38,21 @@ func New(token string) (s *Session, err error) {
StateEnabled: true,
Compress: true,
ShouldReconnectOnError: true,
+ ShouldRetryOnRateLimit: true,
ShardID: 0,
ShardCount: 1,
MaxRestRetries: 3,
Client: &http.Client{Timeout: (20 * time.Second)},
+ Dialer: websocket.DefaultDialer,
UserAgent: "DiscordBot (https://github.com/bwmarrin/discordgo, v" + VERSION + ")",
sequence: new(int64),
LastHeartbeatAck: time.Now().UTC(),
}
- // Initilize the Identify Package with defaults
+ // Initialize the Identify Package with defaults
// These can be modified prior to calling Open()
s.Identify.Compress = true
s.Identify.LargeThreshold = 250
- s.Identify.GuildSubscriptions = true
s.Identify.Properties.OS = runtime.GOOS
s.Identify.Properties.Browser = "DiscordGo v" + VERSION
s.Identify.Intents = IntentsAllWithoutPrivileged