From ed018207226912ee57ecaae06c539aea37e7bb96 Mon Sep 17 00:00:00 2001 From: Wim Date: Mon, 11 Sep 2017 22:45:15 +0200 Subject: Add support for deleting messages across bridges. Currently fully support mattermost,slack and discord. Message deleted on the bridge or received from other bridges will be deleted. Partially support for Gitter. Gitter bridge will delete messages received from other bridges. But if you delete a message on gitter, this deletion will not be sent to other bridges (this is a gitter API limitation, it doesn't propogate edits or deletes via the API) --- bridge/irc/irc.go | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'bridge/irc/irc.go') diff --git a/bridge/irc/irc.go b/bridge/irc/irc.go index d62fe31a..1e0101fa 100644 --- a/bridge/irc/irc.go +++ b/bridge/irc/irc.go @@ -129,6 +129,10 @@ func (b *Birc) JoinChannel(channel config.ChannelInfo) error { } func (b *Birc) Send(msg config.Message) (string, error) { + // ignore delete messages + if msg.Event == config.EVENT_MSG_DELETE { + return "", nil + } flog.Debugf("Receiving %#v", msg) if strings.HasPrefix(msg.Text, "!") { b.Command(&msg) -- cgit v1.2.3