fix misskey-dev/misskey-#10417 (#10418)
This commit is contained in:
parent
e76d3e72db
commit
9629929977
1 changed files with 4 additions and 0 deletions
|
@ -86,6 +86,10 @@ export class ImportCustomEmojisProcessorService {
|
|||
continue;
|
||||
}
|
||||
const emojiInfo = record.emoji;
|
||||
if (!/^[a-zA-Z0-9_]+$/.test(emojiInfo.name)) {
|
||||
this.logger.error(`invalid emojiname: ${emojiInfo.name}`);
|
||||
continue;
|
||||
}
|
||||
const emojiPath = outputPath + '/' + record.fileName;
|
||||
await this.emojisRepository.delete({
|
||||
name: emojiInfo.name,
|
||||
|
|
Loading…
Reference in a new issue