1
0
mirror of https://github.com/misskey-dev/misskey.git synced 2026-05-05 07:45:54 +02:00

admin/emoji/updateの必須項目を減らす 等 (#13449)

* admin/emoji/update enhancement

* add CustomEmojiService.getEmojiByName

* update endpoint

* fix

* Update update.ts

* Update autogen files

* type assertion

* Update CHANGELOG.md
This commit is contained in:
FineArchs
2024-02-25 18:06:26 +09:00
committed by GitHub
parent 2c6f25b710
commit dd48366ed8
4 changed files with 30 additions and 12 deletions

View File

@@ -393,6 +393,11 @@ export class CustomEmojiService implements OnApplicationShutdown {
return this.emojisRepository.findOneBy({ id });
}
@bindThis
public getEmojiByName(name: string): Promise<MiEmoji | null> {
return this.emojisRepository.findOneBy({ name, host: IsNull() });
}
@bindThis
public dispose(): void {
this.cache.dispose();