diff options
author | Wim <wim@42.be> | 2018-06-06 00:51:42 +0200 |
---|---|---|
committer | Wim <wim@42.be> | 2018-06-06 00:51:42 +0200 |
commit | e307069d62ec6ea852c74329f4a6f135135394f7 (patch) | |
tree | 84dcd4a91c50a6e550010a824e1c06406eb4af36 /bridge/sshchat/sshchat.go | |
parent | 91db63294ced789fbcd73cad07b592ec03812f1f (diff) | |
download | matterbridge-msglm-e307069d62ec6ea852c74329f4a6f135135394f7.tar.gz matterbridge-msglm-e307069d62ec6ea852c74329f4a6f135135394f7.tar.bz2 matterbridge-msglm-e307069d62ec6ea852c74329f4a6f135135394f7.zip |
Ignore messages from ourself. (sshchat) Closes #439
Diffstat (limited to 'bridge/sshchat/sshchat.go')
-rw-r--r-- | bridge/sshchat/sshchat.go | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/bridge/sshchat/sshchat.go b/bridge/sshchat/sshchat.go index 343fc66a..6e879e84 100644 --- a/bridge/sshchat/sshchat.go +++ b/bridge/sshchat/sshchat.go @@ -120,6 +120,10 @@ func (b *Bsshchat) handleSshChat() error { wait := true for { if b.r.Scan() { + // ignore messages from ourselves + if !strings.Contains(b.r.Text(), "\033[K") { + continue + } res := strings.Split(stripPrompt(b.r.Text()), ":") if res[0] == "-> Set theme" { wait = false |