fix(web): allow clearing workspace description and context fields

Previously `|| undefined` prevented sending empty strings, making it
impossible to clear these fields once set. Now always send the current
value so the backend COALESCE correctly updates the column.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
yushen 2026-03-24 16:03:39 +08:00
parent 680668ffdb
commit c4a7cf9726

View file

@ -131,8 +131,8 @@ export default function SettingsPage() {
try {
const updated = await api.updateWorkspace(workspace.id, {
name,
description: description || undefined,
context: context || undefined,
description,
context,
});
updateWorkspace(updated);
setSaved(true);