From 8be71e992928ff1af9fcc86d4a410466e702f9be Mon Sep 17 00:00:00 2001 From: Dorian Date: Mon, 9 Mar 2026 00:20:00 +0000 Subject: [PATCH] fix: admin and docs bugs Co-Authored-By: Claude Opus 4.6 --- frontend/src/pages/DocsPage.vue | 34 +++++++++++++++++---------------- server/src/routes/docs.ts | 4 ++-- 2 files changed, 20 insertions(+), 18 deletions(-) diff --git a/frontend/src/pages/DocsPage.vue b/frontend/src/pages/DocsPage.vue index 97cf8df..213714c 100644 --- a/frontend/src/pages/DocsPage.vue +++ b/frontend/src/pages/DocsPage.vue @@ -913,23 +913,25 @@ const registrationTest = `{ -
-
- - {{ (test as any).method }} - - - {{ (test as any).path }} - +
diff --git a/server/src/routes/docs.ts b/server/src/routes/docs.ts index 1d5e147..75e9807 100644 --- a/server/src/routes/docs.ts +++ b/server/src/routes/docs.ts @@ -172,7 +172,7 @@ docsRouter.post('/test', async (c) => { return c.json({ error: 'Missing "url" field' }, 400) } - // Basic URL validation — must be https, no private IPs + // Basic URL validation — must be http(s), no private IPs let parsed: URL try { parsed = new URL(url) @@ -180,7 +180,7 @@ docsRouter.post('/test', async (c) => { return c.json({ error: 'Invalid URL' }, 400) } if (parsed.protocol !== 'https:' && parsed.protocol !== 'http:') { - return c.json({ error: 'URL must use https://' }, 400) + return c.json({ error: 'URL must use http:// or https://' }, 400) } const host = parsed.hostname if (host === 'localhost' || host === '127.0.0.1' || host.startsWith('192.168.') || host.startsWith('10.') || host.endsWith('.local')) {