Fix profile create 307 redirect by adding trailing slash
POST /api/profiles was being redirected to /api/profiles/ (307), which drops the request body. Match the FastAPI route definition. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -705,7 +705,7 @@
|
|||||||
if (!name) { showToast('Profile name required', 'error'); return; }
|
if (!name) { showToast('Profile name required', 'error'); return; }
|
||||||
const body = { name };
|
const body = { name };
|
||||||
if (display) body.display_name = display;
|
if (display) body.display_name = display;
|
||||||
const res = await apiCall('POST', '/api/profiles', body);
|
const res = await apiCall('POST', '/api/profiles/', body);
|
||||||
if (res.ok) {
|
if (res.ok) {
|
||||||
showToast('Profile "' + name + '" created', 'success');
|
showToast('Profile "' + name + '" created', 'success');
|
||||||
setTimeout(() => location.reload(), 1000);
|
setTimeout(() => location.reload(), 1000);
|
||||||
|
|||||||
Reference in New Issue
Block a user