Fix error when r is undefined

This commit is contained in:
Lim Chee Aun 2024-01-11 10:44:37 +08:00
parent 4b9ff0ca5b
commit 500f877d4b

View file

@ -219,7 +219,7 @@ export async function assignFollowedTags(items, instance) {
statusWithFollowedTags.forEach((s) => { statusWithFollowedTags.forEach((s) => {
const { item, sKey, followedTags } = s; const { item, sKey, followedTags } = s;
const r = relationships[item.account.id]; const r = relationships[item.account.id];
if (!r.following) { if (r && !r.following) {
statusFollowedTags[sKey] = followedTags; statusFollowedTags[sKey] = followedTags;
} }
}); });