GitCommitInfo EnsureCommit(GitId id) { if (!Commits.TryGetValue(id, out var v)) { Commits.Add(id, v = new GitCommitInfo(id, Repository)); } return(v); }
public MCommit Commit(CommitId commitId) { MCommit commit; if (!Commits.TryGetValue(commitId, out commit)) { commit = AddNewCommit(commitId); } return(commit); }