Merge branch 'stable-2.11' into stable-2.12

* stable-2.11:
  AccountManager: Update display name only if it is not null.
  ChangeHookValidator: Fix old revision retrieval for root commit
  InlineEdit: Enable inline comments retrieval in change screen
  BanCommitCommand: Do not use commons.collections

Change-Id: Iddb4b9ea60428a271457c082b77afb787606dc24
This commit is contained in:
David Pursehouse
2015-11-12 12:29:24 -08:00
6 changed files with 21 additions and 9 deletions

View File

@@ -881,7 +881,12 @@ public class ChangeScreen extends Screen {
CallbackGroup group = new CallbackGroup();
Timestamp lastReply = myLastReply(info);
if (rev.isEdit()) {
loadFileList(b, rev, lastReply, group, null, null);
// Comments are filtered for the current revision. Use parent
// patch set for edits, as edits themself can never have comments.
RevisionInfo p = RevisionInfo.findEditParentRevision(
info.revisions().values());
List<NativeMap<JsArray<CommentInfo>>> comments = loadComments(p, group);
loadFileList(b, rev, lastReply, group, comments, null);
} else {
loadDiff(b, rev, lastReply, group);
}