fix(server): /emoji to accept @. host expression

This commit is contained in:
tamaina 2022-12-29 14:54:31 +00:00
parent 09078de36b
commit 329ef760bf

View file

@ -232,7 +232,8 @@ export class ClientServerService {
const host = path.split('@')[1]?.replace('.webp', '');
const emoji = await this.emojisRepository.findOneBy({
host: host == null ? IsNull() : host,
// `@.` is the spec of ReactionService.decodeReaction
host: (host == null || host === '.') ? IsNull() : host,
name: name,
});