spec(backend): IdentifiableErrorの場合もエラーメッセージが正常に表示されるように (MisskeyIO#463)
This commit is contained in:
parent
82cc3987c1
commit
4eb645403f
9 changed files with 67 additions and 37 deletions
|
@ -271,7 +271,7 @@ export class NoteCreateService implements OnApplicationShutdown {
|
|||
|
||||
if (this.utilityService.isKeyWordIncluded(data.cw ?? data.text ?? '', meta.prohibitedWords)) {
|
||||
this.logger.error('Request rejected because prohibited words are included', { user: user.id, note: data });
|
||||
throw new IdentifiableError('057d8d3e-b7ca-4f8b-b38c-dcdcbf34dc30');
|
||||
throw new IdentifiableError('057d8d3e-b7ca-4f8b-b38c-dcdcbf34dc30', 'Notes including prohibited words are not allowed.');
|
||||
}
|
||||
|
||||
const inSilencedInstance = this.utilityService.isSilencedHost(meta.silencedHosts, user.host);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue