Fix(frontend): ワードミュートがnullの時にもセンシティブミュートが行われるように (#15364)
* Fix(frontend): ワードミュートがnullの時にもセンシティブミュートが行われるように * Add ChangeLog
This commit is contained in:
parent
ae65aecc0c
commit
28490f3a58
|
@ -4,7 +4,7 @@
|
||||||
-
|
-
|
||||||
|
|
||||||
### Client
|
### Client
|
||||||
-
|
- Fix: 一部環境でセンシティブなファイルを含むノートの非表示が効かない問題
|
||||||
|
|
||||||
### Server
|
### Server
|
||||||
- Fix: 個別お知らせページのmetaタグ出力の条件が間違っていたのを修正
|
- Fix: 個別お知らせページのmetaタグ出力の条件が間違っていたのを修正
|
||||||
|
|
|
@ -304,16 +304,16 @@ function checkMute(noteToCheck: Misskey.entities.Note, mutedWords: Array<string
|
||||||
function checkMute(noteToCheck: Misskey.entities.Note, mutedWords: Array<string | string[]> | undefined | null, checkOnly: false): Array<string | string[]> | false | 'sensitiveMute';
|
function checkMute(noteToCheck: Misskey.entities.Note, mutedWords: Array<string | string[]> | undefined | null, checkOnly: false): Array<string | string[]> | false | 'sensitiveMute';
|
||||||
*/
|
*/
|
||||||
function checkMute(noteToCheck: Misskey.entities.Note, mutedWords: Array<string | string[]> | undefined | null, checkOnly = false): Array<string | string[]> | false | 'sensitiveMute' {
|
function checkMute(noteToCheck: Misskey.entities.Note, mutedWords: Array<string | string[]> | undefined | null, checkOnly = false): Array<string | string[]> | false | 'sensitiveMute' {
|
||||||
if (mutedWords == null) return false;
|
if (mutedWords != null) {
|
||||||
|
const result = checkWordMute(noteToCheck, $i, mutedWords);
|
||||||
|
if (Array.isArray(result)) return result;
|
||||||
|
|
||||||
const result = checkWordMute(noteToCheck, $i, mutedWords);
|
const replyResult = noteToCheck.reply && checkWordMute(noteToCheck.reply, $i, mutedWords);
|
||||||
if (Array.isArray(result)) return result;
|
if (Array.isArray(replyResult)) return replyResult;
|
||||||
|
|
||||||
const replyResult = noteToCheck.reply && checkWordMute(noteToCheck.reply, $i, mutedWords);
|
const renoteResult = noteToCheck.renote && checkWordMute(noteToCheck.renote, $i, mutedWords);
|
||||||
if (Array.isArray(replyResult)) return replyResult;
|
if (Array.isArray(renoteResult)) return renoteResult;
|
||||||
|
}
|
||||||
const renoteResult = noteToCheck.renote && checkWordMute(noteToCheck.renote, $i, mutedWords);
|
|
||||||
if (Array.isArray(renoteResult)) return renoteResult;
|
|
||||||
|
|
||||||
if (checkOnly) return false;
|
if (checkOnly) return false;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue