Populate the revList if empty in -commitForSHA:

I found that at a few points logic was based on items from revList but
at that point in the execution the revList was always empty.
This commit is contained in:
André Berg
2010-04-05 10:52:21 +02:00
parent 8e55c30b38
commit 229387cf80
+4
View File
@@ -349,6 +349,10 @@ static NSString * repositoryBasePath = nil;
return nil;
NSArray *revList = revisionList.projectCommits;
if (!revList) {
[revisionList forceUpdate];
revList = revisionList.projectCommits;
}
for (PBGitCommit *commit in revList)
if ([[commit realSha] isEqualToString:sha])
return commit;