From 24e7eeca0f912a11d4ec2664731b0f929ac26952 Mon Sep 17 00:00:00 2001
From: syuilo <Syuilotan@yahoo.co.jp>
Date: Sun, 30 May 2021 10:05:12 +0900
Subject: [PATCH] fix local emoji detection

https://github.com/misskey-dev/misskey/pull/7526#discussion_r641886612
---
 src/misc/populate-emojis.ts | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/misc/populate-emojis.ts b/src/misc/populate-emojis.ts
index a3f67ccb98..42aaaf0705 100644
--- a/src/misc/populate-emojis.ts
+++ b/src/misc/populate-emojis.ts
@@ -61,7 +61,7 @@ export async function populateEmoji(emojiName: string, noteUserHost: string | nu
 
 	if (emoji == null) return null;
 
-	const isLocal = emojiName.endsWith('@.');
+	const isLocal = emoji.host == null;
 	const url = isLocal ? emoji.url : `${config.url}/proxy/image.png?${query({url: emoji.url})}`;
 
 	return {