fix: properly bypass word mute check if signed out

This commit is contained in:
naskya 2023-10-19 14:39:41 +09:00
parent 797218b863
commit 9a415f9826
Signed by: naskya
GPG key ID: 164DFF24E2D40139
4 changed files with 4 additions and 4 deletions

View file

@ -359,7 +359,7 @@ const isDeleted = ref(false);
const muted = ref(
getWordSoftMute(
note.value,
$i.id,
$i?.id,
defaultStore.state.mutedWords,
defaultStore.state.mutedLangs,
),

View file

@ -234,7 +234,7 @@ const isDeleted = ref(false);
const muted = ref(
getWordSoftMute(
note.value,
$i.id,
$i?.id,
defaultStore.state.mutedWords,
defaultStore.state.mutedLangs,
),

View file

@ -268,7 +268,7 @@ const isDeleted = ref(false);
const muted = ref(
getWordSoftMute(
note.value,
$i.id,
$i?.id,
defaultStore.state.mutedWords,
defaultStore.state.mutedLangs,
),

View file

@ -79,7 +79,7 @@ export function getWordSoftMute(
mutedWords: Array<string | string[]>,
mutedLangs: Array<string | string[]>,
): Muted {
if (note.userId === meId) return NotMuted;
if (meId == null || note.userId === meId) return NotMuted;
if (mutedWords.length > 0) {
const noteMuted = checkWordMute(note, mutedWords);