mirror of
https://github.com/42wim/matterbridge.git
synced 2024-11-21 18:22:00 -08:00
Fix slack channel join
This commit is contained in:
parent
f10251a1a3
commit
0e527a4252
@ -70,9 +70,8 @@ func (b *Bslack) FullOrigin() string {
|
|||||||
func (b *Bslack) JoinChannel(channel string) error {
|
func (b *Bslack) JoinChannel(channel string) error {
|
||||||
// we can only join channels using the API
|
// we can only join channels using the API
|
||||||
if b.Config.UseAPI {
|
if b.Config.UseAPI {
|
||||||
schannel := b.getChannelByName(channel)
|
_, err := b.sc.JoinChannel(channel)
|
||||||
if schannel != nil && !schannel.IsMember {
|
if err != nil {
|
||||||
_, err := b.sc.JoinChannel(schannel.ID)
|
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user