mirror of
https://github.com/paperclipai/paperclip.git
synced 2026-11-29 23:56:43 +01:00
Fix trash button on repo when workspace has no local folder
clearRepoWorkspace was calling updateWorkspace to null out the repo even when there was no local folder, leaving an empty workspace. Now falls through to persistCodebase which correctly removes the entire workspace when both cwd and repoUrl would be null. Co-Authored-By: Paperclip <noreply@paperclip.ing> Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
1 parent
81b4e4f826
commit
1309cc449d
1 file changed
+1
-1
@@ -377,7 +377,7 @@ export function ProjectProperties({ project, onUpdate, onFieldUpdate, getFieldSa
|
||||
: "Delete this workspace repo?",
|
||||
);
|
||||
if (!confirmed) return;
|
||||
if (primaryCodebaseWorkspace) {
|
||||
if (primaryCodebaseWorkspace && hasLocalFolder) {
|
||||
updateWorkspace.mutate({
|
||||
workspaceId: primaryCodebaseWorkspace.id,
|
||||
data: { repoUrl: null, repoRef: null, defaultRef: null, sourceType: deriveSourceType(codebase.localFolder, null) },
|
||||
|
||||
Reference in new issue
Block a user