Skip to content

Commit 34ed8e2

Browse files
trumbittaroboquat
authored andcommitted
[server] set default branch for BitBucket provider
closes #7325
1 parent 6cdee7a commit 34ed8e2

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

components/server/src/bitbucket/bitbucket-repository-provider.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,8 @@ export class BitbucketRepositoryProvider implements RepositoryProvider {
2929
const description = repo.description;
3030
const avatarUrl = repo.owner!.links!.avatar!.href;
3131
const webUrl = repo.links!.html!.href;
32-
return { host, owner, name, cloneUrl, description, avatarUrl, webUrl };
32+
const defaultBranch = repo.mainbranch?.name;
33+
return { host, owner, name, cloneUrl, description, avatarUrl, webUrl, defaultBranch };
3334
}
3435

3536
async getBranch(user: User, owner: string, repo: string, branchName: string): Promise<Branch> {

0 commit comments

Comments
 (0)