are
This commit is contained in:
parent
103c4190eb
commit
95310f07ac
|
@ -28,7 +28,7 @@ export class AccountUpdateService {
|
||||||
|
|
||||||
@bindThis
|
@bindThis
|
||||||
public async publishToFollowers(userId: MiUser['id']) {
|
public async publishToFollowers(userId: MiUser['id']) {
|
||||||
console.time('AccountUpdateService.publishToFollowers');
|
console.time('time AccountUpdateService.publishToFollowers');
|
||||||
const user = await this.usersRepository.findOneBy({ id: userId });
|
const user = await this.usersRepository.findOneBy({ id: userId });
|
||||||
if (user == null) throw new Error('user not found');
|
if (user == null) throw new Error('user not found');
|
||||||
|
|
||||||
|
@ -38,6 +38,6 @@ export class AccountUpdateService {
|
||||||
this.apDeliverManagerService.deliverToFollowers(user, content);
|
this.apDeliverManagerService.deliverToFollowers(user, content);
|
||||||
this.relayService.deliverToRelays(user, content);
|
this.relayService.deliverToRelays(user, content);
|
||||||
}
|
}
|
||||||
console.timeEnd('AccountUpdateService.publishToFollowers');
|
console.timeEnd('time AccountUpdateService.publishToFollowers');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -344,9 +344,9 @@ export class GlobalEventService {
|
||||||
|
|
||||||
@bindThis
|
@bindThis
|
||||||
public publishMainStream<K extends keyof MainEventTypes>(userId: MiUser['id'], type: K, value?: MainEventTypes[K]): void {
|
public publishMainStream<K extends keyof MainEventTypes>(userId: MiUser['id'], type: K, value?: MainEventTypes[K]): void {
|
||||||
console.time('GlobalEventService.publishMainStream');
|
console.time('time GlobalEventService.publishMainStream');
|
||||||
this.publish(`mainStream:${userId}`, type, typeof value === 'undefined' ? null : value);
|
this.publish(`mainStream:${userId}`, type, typeof value === 'undefined' ? null : value);
|
||||||
console.time('GlobalEventService.publishMainStream');
|
console.time('time GlobalEventService.publishMainStream');
|
||||||
}
|
}
|
||||||
|
|
||||||
@bindThis
|
@bindThis
|
||||||
|
|
Loading…
Reference in New Issue