diff options
author | HampusM <hampus@hampusmat.com> | 2021-08-05 17:03:36 +0200 |
---|---|---|
committer | HampusM <hampus@hampusmat.com> | 2021-08-05 17:03:36 +0200 |
commit | 8c6a59cd766fead4998c957d86a0e33fd58d1cde (patch) | |
tree | ff2cd43a4a5dafb27348fc320784c39f1fe9c941 /packages/server/src/git/commit.ts | |
parent | 22bf491be5f25bccf779be53b2ad37836f0850b8 (diff) |
The tree API has a branch query param & made repository branch less hardcoded
Diffstat (limited to 'packages/server/src/git/commit.ts')
-rw-r--r-- | packages/server/src/git/commit.ts | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/packages/server/src/git/commit.ts b/packages/server/src/git/commit.ts index e0b3bbb..cf1ac5a 100644 --- a/packages/server/src/git/commit.ts +++ b/packages/server/src/git/commit.ts @@ -104,12 +104,12 @@ export class Commit { } /** - * Returns the master commit of a repository + * Returns the most recent commit of the repository's branch * * @param owner - A repository * @returns An instance of a commit */ - public static async masterCommit(owner: Repository): Promise<Commit> { - return new Commit(owner, await owner.ng_repository.getMasterCommit()); + public static async branchCommit(owner: Repository): Promise<Commit> { + return new Commit(owner, await owner.ng_repository.getBranchCommit(owner.branch_name)); } }
\ No newline at end of file |