Skip to content

Commit 558d437

Browse files
committed
Merge branch 'claude/fix-issue-662-aVtgd' into 'master'
Set default branch to main for clone creation (#662) Closes #662 See merge request postgres-ai/database-lab!1075
2 parents 0fe7abe + 53b9493 commit 558d437

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

  • ui/packages/shared/pages/CreateClone

ui/packages/shared/pages/CreateClone/index.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,8 @@ export const CreateClone = observer((props: Props) => {
114114

115115
const branches = (await stores.main.getBranches(props.instanceId)) ?? []
116116

117-
let initiallySelectedBranch = branches[0];
117+
const mainBranch = branches.find((branch) => branch.name === 'main')
118+
let initiallySelectedBranch = mainBranch?.name ?? branches[0];
118119

119120
if (initialBranch) {
120121
const foundBranch = branches.find((branch) => branch.name === initialBranch)

0 commit comments

Comments
 (0)