From 2f36db914262c079ef2843faeaf5ac42b202f3d0 Mon Sep 17 00:00:00 2001 From: Cory McWilliams Date: Sat, 4 Jan 2025 21:05:24 -0500 Subject: [PATCH] ssb: Don't display mentions for tags that are used in the text of a message. --- apps/ssb.json | 2 +- apps/ssb/tf-message.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/apps/ssb.json b/apps/ssb.json index ff94a5cd..2be719d5 100644 --- a/apps/ssb.json +++ b/apps/ssb.json @@ -1,5 +1,5 @@ { "type": "tildefriends-app", "emoji": "🦀", - "previous": "&51G4JroQ8+3iBddnFQoTVXYrLTtZ/egQ+0NU4z60zBc=.sha256" + "previous": "&MT6BBjSYx78iHX7+KHJzCnHYGPOJB4Vng8Dw2ymDaS4=.sha256" } diff --git a/apps/ssb/tf-message.js b/apps/ssb/tf-message.js index db0562f1..8314f908 100644 --- a/apps/ssb/tf-message.js +++ b/apps/ssb/tf-message.js @@ -253,7 +253,7 @@ class TfMessageElement extends LitElement { render_mentions() { let mentions = this.message?.content?.mentions || []; mentions = mentions.filter( - (x) => this.message?.content?.text?.indexOf(x.link) === -1 + (x) => this.message?.content?.text?.indexOf(typeof(x) === 'string' ? x : x.link) === -1 ); if (mentions.length) { let self = this;