Skip to content

Commit 9306b95

Browse files
fix: personal agents
1 parent 8c0b215 commit 9306b95

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

gui/src/pages/gui/Chat.tsx

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -178,7 +178,9 @@ export function Chat() {
178178
// Handle background mode specially
179179
if (currentMode === "background" && !isCurrentlyInEdit) {
180180
// Background mode triggers agent creation instead of chat
181-
const organizationId = selectCurrentOrg(stateSnapshot)?.id;
181+
const currentOrg = selectCurrentOrg(stateSnapshot);
182+
const organizationId =
183+
currentOrg?.id !== "personal" ? currentOrg?.id : undefined;
182184
ideMessenger.post("createBackgroundAgent", {
183185
editorState,
184186
organizationId,
@@ -479,7 +481,8 @@ export function Chat() {
479481
{mode === "background" ? (
480482
<BackgroundModeView
481483
onCreateAgent={(editorState) => {
482-
const organizationId = currentOrg?.id;
484+
const organizationId =
485+
currentOrg?.id !== "personal" ? currentOrg?.id : undefined;
483486
ideMessenger.post("createBackgroundAgent", {
484487
editorState,
485488
organizationId,

0 commit comments

Comments
 (0)