The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.
TypeScript aialternativeauthdatabasedenoembeddingsexamplefirebasenextjsoauth2pgvectorpostgispostgrespostgresqlpostgrestrealtimesupabasevectorswebsockets
fix: remove git branches from merge requests dropdown (#41817)
Han Qiao9b152f0ce58b
diff --git a/apps/studio/components/interfaces/BranchManagement/BranchSelector.tsx b/apps/studio/components/interfaces/BranchManagement/BranchSelector.tsxindex 9714d8e5e06..44838d8a866 100644--- a/apps/studio/components/interfaces/BranchManagement/BranchSelector.tsx+++ b/apps/studio/components/interfaces/BranchManagement/BranchSelector.tsx@@ -34,9 +34,9 @@ export const BranchSelector = ({const [open, setOpen] = useState(false)const [selectedBranch, setSelectedBranch] = useState<Branch | null>(null)- // Filter out branches that are already ready for review and the main branch+ // Filter out branches that are already ready for review or linked to a github branchconst availableBranches = branches.filter(- (branch) => !branch.is_default && !branch.review_requested_at+ (branch) => !branch.is_default && !branch.review_requested_at && !branch.git_branch)const handleBranchSelect = (branch: Branch) => {diff --git a/apps/studio/pages/project/[ref]/merge.tsx b/apps/studio/pages/project/[ref]/merge.tsxindex bdb1eed00d5..67d42a647b8 100644--- a/apps/studio/pages/project/[ref]/merge.tsx+++ b/apps/studio/pages/project/[ref]/merge.tsx@@ -369,7 +369,11 @@ const MergePage: NextPageWithLayout = () => {}const isMergeDisabled =- !combinedHasChanges || isCombinedDiffLoading || isBranchOutOfDateOverall || isWorkflowRunning+ !combinedHasChanges ||+ isCombinedDiffLoading ||+ isBranchOutOfDateOverall ||+ isWorkflowRunning ||+ Boolean(mainBranch?.git_branch)const primaryActions = (<div className="flex items-end gap-2">@@ -388,7 +392,9 @@ const MergePage: NextPageWithLayout = () => {? 'No changes to merge': isWorkflowRunning? 'Workflow is currently running'- : 'Unable to merge at this time',+ : Boolean(mainBranch?.git_branch)+ ? 'Deploy to production from GitHub is enabled'+ : 'Unable to merge at this time',},}}type="primary"@@ -404,7 +410,6 @@ const MergePage: NextPageWithLayout = () => {type="primary"loading={isMerging || isSubmitting}onClick={() => setShowConfirmDialog(true)}- disabled={isBranchOutOfDateOverall}icon={<GitMerge size={16} strokeWidth={1.5} className="text-brand" />}>Merge branch