summaryrefslogtreecommitdiffstats
path: root/gateway/gateway.go
diff options
context:
space:
mode:
Diffstat (limited to 'gateway/gateway.go')
-rw-r--r--gateway/gateway.go8
1 files changed, 8 insertions, 0 deletions
diff --git a/gateway/gateway.go b/gateway/gateway.go
index 580e129d..63da4bba 100644
--- a/gateway/gateway.go
+++ b/gateway/gateway.go
@@ -106,6 +106,10 @@ func (gw *Gateway) mapIgnores() {
func (gw *Gateway) getDestChannel(msg *config.Message, dest string) []string {
channels := gw.ChannelsIn[msg.Account]
+ // broadcast to every out channel (irc QUIT)
+ if msg.Event == config.EVENT_JOIN_LEAVE && msg.Channel == "" {
+ return gw.ChannelsOut[dest]
+ }
for _, channel := range channels {
if channel == msg.Channel {
return gw.ChannelsOut[dest]
@@ -118,6 +122,10 @@ func (gw *Gateway) handleMessage(msg config.Message, dest *bridge.Bridge) {
if gw.ignoreMessage(&msg) {
return
}
+ // only relay join/part when configged
+ if msg.Event == config.EVENT_JOIN_LEAVE && !gw.Bridges[dest.Account].Config.ShowJoinPart {
+ return
+ }
originchannel := msg.Channel
channels := gw.getDestChannel(&msg, dest.Account)
for _, channel := range channels {