Merge changes Ie9229923,Ibe1cd165

* changes:
  Change API: Add convenience get() and info() methods
  ChangeJson: Fix reviewed property initialization
This commit is contained in:
Shawn Pearce
2014-02-08 01:41:06 +00:00
committed by Gerrit Code Review
5 changed files with 36 additions and 12 deletions

View File

@@ -227,6 +227,9 @@ public class ChangeJson {
private ChangeInfo format(ChangeData cd, Optional<PatchSet.Id> limitToPsId)
throws OrmException {
accountLoader = accountLoaderFactory.create(has(DETAILED_ACCOUNTS));
if (has(REVIEWED)) {
ensureReviewedLoaded(Collections.singleton(cd));
}
ChangeInfo res = toChangeInfo(cd, limitToPsId);
accountLoader.fill();
return res;