1
0
Fork 0
mirror of https://github.com/diamondburned/arikawa.git synced 2024-11-27 17:23:00 +00:00

Gateway: Made Shard field empty for default

This commit is contained in:
diamondburned 2020-12-30 23:43:08 -08:00
parent f3f075b27f
commit 05de2d7b61

View file

@ -18,21 +18,13 @@ var DefaultPresence *UpdateStatusData
type Identifier struct {
IdentifyData
IdentifyShortLimit *rate.Limiter // optional
IdentifyGlobalLimit *rate.Limiter // optional
IdentifyShortLimit *rate.Limiter `json:"-"` // optional
IdentifyGlobalLimit *rate.Limiter `json:"-"` // optional
}
// DefaultIdentifier creates a new default Identifier
func DefaultIdentifier(token string) *Identifier {
return NewIdentifier(IdentifyData{
Token: token,
Properties: DefaultIdentity,
Shard: DefaultShard,
Presence: DefaultPresence,
Compress: true,
LargeThreshold: 50,
})
return NewIdentifier(DefaultIdentifyData(token))
}
// NewIdentifier creates a new identifier with the given IdentifyData and
@ -92,7 +84,6 @@ func DefaultIdentifyData(token string) IdentifyData {
return IdentifyData{
Token: token,
Properties: DefaultIdentity,
Shard: DefaultShard,
Presence: DefaultPresence,
Compress: true,