Fixing #835 and writing config.go and matterbridge.toml.sample entries

This commit is contained in:
Humorhenker
2019-06-03 00:12:23 +02:00
parent e610fb3201
commit a9c76db532
3 changed files with 13 additions and 2 deletions

View File

@@ -79,6 +79,7 @@ type Protocol struct {
ColorNicks bool // only irc for now
Debug bool // general
DebugLevel int // only for irc now
DelayedEnable bool // only for xmpp now
EditSuffix string // mattermost, slack, discord, telegram, gitter
EditDisable bool // mattermost, slack, discord, telegram, gitter
IconURL string // mattermost, slack

View File

@@ -331,6 +331,11 @@ func (b *Bxmpp) skipMessage(message xmpp.Chat) bool {
return true
}
// skip delayed messages
return message.Stamp.IsZero()
// disable delayed skiping #835
if b.GetBool("DelayedEnable") {
return false
} else {
// skip delayed messages
return message.Stamp.IsZero()
}
}

View File

@@ -277,6 +277,11 @@ StripNick=false
#OPTIONAL (default false)
ShowTopicChange=false
#Enable to fix a problem where xmpp servers dont send timestamps and all messages are skipped. See https://github.com/42wim/matterbridge/issues/835
#This will bypass the check for delayed messages.
#OPTIONAL (default false)
DelayedEnable=false
###################################################################
#mattermost section
###################################################################