1
0
mirror of https://github.com/hotomoe/hotomoe synced 2024-12-12 05:38:12 +09:00

spec(backend): リモートの投稿にも禁止ワードを適用 (MisskeyIO#437)

This commit is contained in:
まっちゃとーにゅ 2024-02-12 06:13:39 +09:00 committed by GitHub
parent a69efd722a
commit 0df6dbd919
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -268,10 +268,8 @@ export class NoteCreateService implements OnApplicationShutdown {
} }
} }
if (!user.host) { if (this.utilityService.isKeyWordIncluded(data.cw ?? data.text ?? '', meta.prohibitedWords)) {
if (this.utilityService.isKeyWordIncluded(data.cw ?? data.text ?? '', meta.prohibitedWords)) { throw new IdentifiableError('057d8d3e-b7ca-4f8b-b38c-dcdcbf34dc30');
throw new IdentifiableError('057d8d3e-b7ca-4f8b-b38c-dcdcbf34dc30');
}
} }
const inSilencedInstance = this.utilityService.isSilencedHost(meta.silencedHosts, user.host); const inSilencedInstance = this.utilityService.isSilencedHost(meta.silencedHosts, user.host);