Fix item mention of own items (#1250)

This commit is contained in:
ekzyis 2024-07-02 21:22:58 +02:00 committed by GitHub
parent 9145f290dc
commit 2dd96f4b83
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 2 additions and 1 deletions

View File

@ -35,7 +35,8 @@ export const getItemMentions = async ({ text }, { me, models }) => {
if (refs?.length > 0) {
const referee = await models.item.findMany({
where: {
id: { in: refs }
id: { in: refs },
userId: { not: me?.id || USER_ID.anon }
}
})
return referee.map(r => ({ refereeId: r.id }))