From 70ee4bd4ef7c3863f7177496af9a63f891eb0563 Mon Sep 17 00:00:00 2001 From: 4sterisk <4sterisk@ymail.ne.jp> Date: Thu, 12 Sep 2024 01:15:15 +0900 Subject: [PATCH] =?UTF-8?q?reactionsCount=E3=82=92=E7=84=A1=E5=8A=B9?= =?UTF-8?q?=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/backend/src/server/api/endpoints/stats.ts | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/packages/backend/src/server/api/endpoints/stats.ts b/packages/backend/src/server/api/endpoints/stats.ts index 1e6983177f64..a5078552e5e8 100644 --- a/packages/backend/src/server/api/endpoints/stats.ts +++ b/packages/backend/src/server/api/endpoints/stats.ts @@ -4,7 +4,7 @@ */ import { Inject, Injectable } from '@nestjs/common'; -import type { InstancesRepository, NoteReactionsRepository } from '@/models/_.js'; +import type { InstancesRepository } from '@/models/_.js'; import { Endpoint } from '@/server/api/endpoint-base.js'; import { DI } from '@/di-symbols.js'; import NotesChart from '@/core/chart/charts/notes.js'; @@ -63,9 +63,6 @@ export default class extends Endpoint { // eslint- @Inject(DI.instancesRepository) private instancesRepository: InstancesRepository, - @Inject(DI.noteReactionsRepository) - private noteReactionsRepository: NoteReactionsRepository, - private notesChart: NotesChart, private usersChart: UsersChart, ) { @@ -79,11 +76,9 @@ export default class extends Endpoint { // eslint- const originalUsersCount = usersChart.local.total[0]; const [ - reactionsCount, //originalReactionsCount, instances, ] = await Promise.all([ - this.noteReactionsRepository.count({ cache: 3600000 }), // 1 hour //this.noteReactionsRepository.count({ where: { userHost: IsNull() }, cache: 3600000 }), this.instancesRepository.count({ cache: 3600000 }), ]); @@ -93,7 +88,7 @@ export default class extends Endpoint { // eslint- originalNotesCount, usersCount, originalUsersCount, - reactionsCount, + reactionsCount: 0, //originalReactionsCount, instances, driveUsageLocal: 0,