mirror of
https://github.com/tiennm99/coolify.git
synced 2026-04-17 21:20:29 +00:00
feat: Prioritize main/master branches in branch selection dropdown
Add sortBranchesByPriority() helper to sort branches with priority: main first, master second, then alphabetically. This improves UX by pre-selecting the most commonly used default branches.
This commit is contained in:
@@ -138,6 +138,7 @@ class GithubPrivateRepository extends Component
|
||||
$this->loadBranchByPage();
|
||||
}
|
||||
}
|
||||
$this->branches = sortBranchesByPriority($this->branches);
|
||||
$this->selected_branch_name = data_get($this->branches, '0.name', 'main');
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user