From 0e2e4c353f6d2fd2cc650007ec2f6a876acde8f7 Mon Sep 17 00:00:00 2001 From: kakkokari-gtyih Date: Thu, 8 Feb 2024 20:17:56 +0900 Subject: [PATCH] =?UTF-8?q?=E3=83=9E=E3=83=BC=E3=82=B8=E3=83=9F=E3=82=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/frontend/src/components/MkApprovalUser.vue | 5 +++-- packages/frontend/src/pages/admin/index.vue | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/packages/frontend/src/components/MkApprovalUser.vue b/packages/frontend/src/components/MkApprovalUser.vue index 06c3e6b1aae4..edc73c0848e1 100644 --- a/packages/frontend/src/components/MkApprovalUser.vue +++ b/packages/frontend/src/components/MkApprovalUser.vue @@ -38,6 +38,7 @@ import MkFolder from '@/components/MkFolder.vue'; import MkButton from '@/components/MkButton.vue'; import { i18n } from '@/i18n.js'; import * as os from '@/os.js'; +import { misskeyApi } from '@/scripts/misskey-api.js'; const props = defineProps<{ user: Misskey.entities.User; @@ -47,7 +48,7 @@ const reason = ref(''); const email = ref(''); function getReason() { - return os.api('admin/show-user', { + return misskeyApi('admin/show-user', { userId: props.user.id, }).then(info => { reason.value = info.signupReason; @@ -93,7 +94,7 @@ async function approveAccount() { text: i18n.ts.registerApproveConfirmDescription, }); if (confirm.canceled) return; - await os.api('admin/approve-user', { userId: props.user.id }); + await misskeyApi('admin/approve-user', { userId: props.user.id }); emits('deleted', props.user.id); } diff --git a/packages/frontend/src/pages/admin/index.vue b/packages/frontend/src/pages/admin/index.vue index b0a7ca2806e1..ac426b1064c1 100644 --- a/packages/frontend/src/pages/admin/index.vue +++ b/packages/frontend/src/pages/admin/index.vue @@ -72,7 +72,7 @@ misskeyApi('admin/abuse-user-reports', { if (reports.length > 0) thereIsUnresolvedAbuseReport.value = true; }); -os.api('admin/show-users', { +misskeyApi('admin/show-users', { state: 'approved', origin: 'local', limit: 1,