enhance: improve federation chart

This commit is contained in:
syuilo
2022-02-10 17:45:12 +09:00
parent 7ba5512a65
commit 0afebcfd9e
25 changed files with 199 additions and 64 deletions

View File

@ -1,6 +1,5 @@
import { Instance } from '@/models/entities/instance';
import { Instances } from '@/models/index';
import { federationChart } from '@/services/chart/index';
import { genId } from '@/misc/gen-id';
import { toPuny } from '@/misc/convert-host';
import { Cache } from '@/misc/cache';
@ -23,8 +22,6 @@ export async function registerOrFetchInstanceDoc(host: string): Promise<Instance
lastCommunicatedAt: new Date(),
}).then(x => Instances.findOneOrFail(x.identifiers[0]));
federationChart.update(true);
cache.set(host, i);
return i;
} else {