perf: use replaceAll instead of regex

This commit is contained in:
syuilo
2023-02-03 17:44:25 +09:00
parent 5173ed37f9
commit 1d39f785f1
2 changed files with 3 additions and 3 deletions

View File

@@ -274,7 +274,7 @@ export class ApRendererService {
} as any;
if (reaction.startsWith(':')) {
const name = reaction.replace(/:/g, '');
const name = reaction.replaceAll(':', '');
const emoji = await this.emojisRepository.findOneBy({
name,
host: IsNull(),