From 47322b35ff0559136e0fb0de034acf723a38f234 Mon Sep 17 00:00:00 2001 From: MeiMei <30769358+mei23@users.noreply.github.com> Date: Mon, 30 Mar 2020 11:45:57 +0900 Subject: [PATCH] =?UTF-8?q?API=E3=81=AE=E6=A8=A9=E9=99=90=E8=A8=AD?= =?UTF-8?q?=E5=AE=9A=E6=BC=8F=E3=82=8C=E3=82=92=E4=BF=AE=E6=AD=A3=20(#6202?= =?UTF-8?q?)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Fix: 権限設定漏れ * requireAdmin --- src/server/api/endpoints/admin/get-table-stats.ts | 3 ++- src/server/api/endpoints/admin/server-info.ts | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/server/api/endpoints/admin/get-table-stats.ts b/src/server/api/endpoints/admin/get-table-stats.ts index 58c9c6e7c3..5717110b25 100644 --- a/src/server/api/endpoints/admin/get-table-stats.ts +++ b/src/server/api/endpoints/admin/get-table-stats.ts @@ -2,7 +2,8 @@ import define from '../../define'; import { getConnection } from 'typeorm'; export const meta = { - requireCredential: false as const, + requireCredential: true as const, + requireAdmin: true, desc: { 'en-US': 'Get table stats' diff --git a/src/server/api/endpoints/admin/server-info.ts b/src/server/api/endpoints/admin/server-info.ts index 2563ff52ef..1804b9ac70 100644 --- a/src/server/api/endpoints/admin/server-info.ts +++ b/src/server/api/endpoints/admin/server-info.ts @@ -5,7 +5,8 @@ import define from '../../define'; import redis from '../../../../db/redis'; export const meta = { - requireCredential: false as const, + requireCredential: true as const, + requireAdmin: true, desc: { },