良い感じに

This commit is contained in:
syuilo
2018-05-07 04:08:39 +09:00
parent a549327170
commit 6785f50a1f
2 changed files with 157 additions and 194 deletions

View File

@ -1,10 +1,10 @@
import { toUnicode, toASCII } from 'punycode';
import User from '../models/user';
import User, { IUser } from '../models/user';
import webFinger from './webfinger';
import config from '../config';
import { createPerson } from './activitypub/models/person';
export default async (username, _host, option?) => {
export default async (username, _host, option?): Promise<IUser> => {
const usernameLower = username.toLowerCase();
const hostAscii = toASCII(_host).toLowerCase();
const host = toUnicode(hostAscii);