Fixes issues with merge commits

This commit is contained in:
Eric Amodio
2017-03-26 13:50:04 -04:00
parent 8b5eed4714
commit 3856cfd110
6 changed files with 38 additions and 18 deletions

View File

@@ -12,6 +12,7 @@ export class GitLogCommit extends GitCommit {
fileStatuses: { status: GitStatusFileStatus, fileName: string, originalFileName?: string }[];
nextSha?: string;
nextFileName?: string;
parentShas: string[];
status: GitStatusFileStatus;
constructor(
@@ -43,6 +44,10 @@ export class GitLogCommit extends GitCommit {
}
}
get isMerge() {
return this.parentShas && this.parentShas.length > 1;
}
get nextShortSha() {
return this.nextSha && this.nextSha.substring(0, 8);
}