Skip to content

Commit

Permalink
Do not check cache on deleted messages (mattermost). Fixes #1555
Browse files Browse the repository at this point in the history
  • Loading branch information
42wim committed Oct 24, 2021
1 parent b1f4031 commit f81fd48
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion matterclient/messages.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import (
func (m *MMClient) parseActionPost(rmsg *Message) {
// add post to cache, if it already exists don't relay this again.
// this should fix reposts
if ok, _ := m.lruCache.ContainsOrAdd(digestString(rmsg.Raw.Data["post"].(string)), true); ok {
if ok, _ := m.lruCache.ContainsOrAdd(digestString(rmsg.Raw.Data["post"].(string)), true); ok && rmsg.Raw.Event != model.WEBSOCKET_EVENT_POST_DELETED {
m.logger.Debugf("message %#v in cache, not processing again", rmsg.Raw.Data["post"].(string))
rmsg.Text = ""
return
Expand Down

0 comments on commit f81fd48

Please # to comment.