service: don't send PART if not joined in "channel delete"
This commit is contained in:
parent
6ea4e2e1eb
commit
1f98b1f054
|
@ -1432,7 +1432,7 @@ func handleServiceChannelDelete(ctx *serviceContext, params []string) error {
|
||||||
return fmt.Errorf("failed to delete channel: %v", err)
|
return fmt.Errorf("failed to delete channel: %v", err)
|
||||||
}
|
}
|
||||||
|
|
||||||
if uc := network.conn; uc != nil {
|
if uc := network.conn; uc != nil && uc.channels.Has(name) {
|
||||||
uc.SendMessage(ctx, &irc.Message{
|
uc.SendMessage(ctx, &irc.Message{
|
||||||
Command: "PART",
|
Command: "PART",
|
||||||
Params: []string{name},
|
Params: []string{name},
|
||||||
|
|
Loading…
Reference in a new issue