feat(server): Fetch icon url of an instance (#6591)

* feat(server): Fetch icon url of an instance

Resolve #6589

* chore: Rename the function
This commit is contained in:
syuilo
2020-07-26 11:04:07 +09:00
committed by GitHub
parent cf9266eab9
commit f1ef85b636
9 changed files with 183 additions and 80 deletions

View File

@@ -26,7 +26,7 @@ import { validActor } from '../../../remote/activitypub/type';
import { getConnection } from 'typeorm';
import { ensure } from '../../../prelude/ensure';
import { toArray } from '../../../prelude/array';
import { fetchNodeinfo } from '../../../services/fetch-nodeinfo';
import { fetchInstanceMetadata } from '../../../services/fetch-instance-metadata';
const logger = apLogger;
@@ -204,7 +204,7 @@ export async function createPerson(uri: string, resolver?: Resolver): Promise<Us
registerOrFetchInstanceDoc(host).then(i => {
Instances.increment({ id: i.id }, 'usersCount', 1);
instanceChart.newUser(i.host);
fetchNodeinfo(i);
fetchInstanceMetadata(i);
});
usersChart.update(user!, true);