mirror of
https://github.com/42wim/matterbridge
synced 2024-11-17 03:26:07 +00:00
parent
fc5e3a6728
commit
df02f51c56
@ -76,9 +76,10 @@ func (b *Bdiscord) Connect() error {
|
|||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
serverName := strings.Replace(b.GetString("Server"), "ID:", "", -1)
|
||||||
b.Nick = userinfo.Username
|
b.Nick = userinfo.Username
|
||||||
for _, guild := range guilds {
|
for _, guild := range guilds {
|
||||||
if guild.Name == b.GetString("Server") {
|
if guild.Name == serverName || guild.ID == serverName {
|
||||||
b.Channels, err = b.c.GuildChannels(guild.ID)
|
b.Channels, err = b.c.GuildChannels(guild.ID)
|
||||||
b.guildID = guild.ID
|
b.guildID = guild.ID
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
Loading…
Reference in New Issue
Block a user