summaryrefslogtreecommitdiffstats
path: root/bridge/irc
diff options
context:
space:
mode:
authorWim <wim@42.be>2018-03-06 21:34:55 +0100
committerWim <wim@42.be>2018-03-06 21:35:47 +0100
commite5989adf92cd5ea007b5e7d50580579f8581fee2 (patch)
tree30592393820ff17d2e8f3cc9551cf83ce7d5f3e6 /bridge/irc
parent9e5da2f9d7384f2d17ed3bc18bcca7b7c07e6252 (diff)
downloadmatterbridge-msglm-e5989adf92cd5ea007b5e7d50580579f8581fee2.tar.gz
matterbridge-msglm-e5989adf92cd5ea007b5e7d50580579f8581fee2.tar.bz2
matterbridge-msglm-e5989adf92cd5ea007b5e7d50580579f8581fee2.zip
Add support for NoSendJoinPart. Closes #382
Diffstat (limited to 'bridge/irc')
-rw-r--r--bridge/irc/irc.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/bridge/irc/irc.go b/bridge/irc/irc.go
index df1b7df7..ccaf0276 100644
--- a/bridge/irc/irc.go
+++ b/bridge/irc/irc.go
@@ -302,6 +302,9 @@ func (b *Birc) handleJoinPart(client *girc.Client, event girc.Event) {
}
}
if event.Source.Name != b.Nick {
+ if b.GetBool("nosendjoinpart") {
+ return
+ }
b.Log.Debugf("<= Sending JOIN_LEAVE event from %s to gateway", b.Account)
msg := config.Message{Username: "system", Text: event.Source.Name + " " + strings.ToLower(event.Command) + "s", Channel: channel, Account: b.Account, Event: config.EVENT_JOIN_LEAVE}
b.Log.Debugf("<= Message is %#v", msg)