From ae16b45c1170cd4361b8fac9fadc225101803f9a Mon Sep 17 00:00:00 2001 From: syuilo Date: Sat, 13 Apr 2019 16:54:21 +0900 Subject: Fix bug --- src/queue/processors/inbox.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/queue') diff --git a/src/queue/processors/inbox.ts b/src/queue/processors/inbox.ts index 4deaef2ae3..05fed0566d 100644 --- a/src/queue/processors/inbox.ts +++ b/src/queue/processors/inbox.ts @@ -12,7 +12,7 @@ import { Instances, Users, UserPublickeys } from '../../models'; import { instanceChart } from '../../services/chart'; import { UserPublickey } from '../../models/entities/user-publickey'; import fetchMeta from '../../misc/fetch-meta'; -import { toPuny } from '../../misc/convert-host'; +import { toPuny, toPunyNullable } from '../../misc/convert-host'; import { validActor } from '../../remote/activitypub/type'; import { ensure } from '../../prelude/ensure'; @@ -36,7 +36,7 @@ export default async (job: Bull.Job): Promise => { if (keyIdLower.startsWith('acct:')) { const acct = parseAcct(keyIdLower.slice('acct:'.length)); - const host = acct.host ? toPuny(acct.host) : null; + const host = toPunyNullable(acct.host); const username = toPuny(acct.username); if (host === null) { -- cgit v1.2.3-freya