fix: ignore if post boosted by relay is local

This commit is contained in:
Namekuji 2023-06-30 18:13:07 -04:00
parent 44bf99e0c1
commit 159f788696
No known key found for this signature in database
GPG Key ID: 1D62332C07FBA532
1 changed files with 2 additions and 1 deletions

View File

@ -472,7 +472,8 @@ export default async (
.map((relay) => new URL(relay.inbox).host)
.includes(note.userHost);
if (boostedByRelay && data.renote) {
if (boostedByRelay && data.renote && data.renote.userHost) {
/* A relay boosted a remote post. */
// Use Redis transaction for atomicity
const key = `publishedNote:${data.renote.id}`;
await redisClient.watch(key);