diff --git a/packages/frontend/src/pages/instance-info.vue b/packages/frontend/src/pages/instance-info.vue index a2a60a1d5b..469b052b61 100644 --- a/packages/frontend/src/pages/instance-info.vue +++ b/packages/frontend/src/pages/instance-info.vue @@ -337,6 +337,7 @@ async function resumeDelivery(): Promise { } async function toggleNSFW(): Promise { + if (!iAmModerator) return; if (!instance.value) throw new Error('No instance?'); await misskeyApi('admin/federation/update-instance', { host: instance.value.host, @@ -345,6 +346,7 @@ async function toggleNSFW(): Promise { } async function toggleRejectReports(): Promise { + if (!iAmModerator) return; if (!instance.value) throw new Error('No instance?'); await misskeyApi('admin/federation/update-instance', { host: instance.value.host, @@ -364,6 +366,7 @@ function refreshMetadata(): void { } async function deleteAllFiles(): Promise { + if (!iAmModerator) return; if (!instance.value) throw new Error('No instance?'); const confirm = await os.confirm({ @@ -383,6 +386,7 @@ async function deleteAllFiles(): Promise { } async function severAllFollowRelations(): Promise { + if (!iAmModerator) return; if (!instance.value) throw new Error('No instance?'); const confirm = await os.confirm({