ReceiveCommits.ReplaceRequest: Parse prior commit body earlier
In I4768e35b, PatchSetUtil.getChangeKind was added, which depends on the body of both commits being parsed. Change-Id: Ia9d09b154988becb2802418a35b4b2edccb58284
This commit is contained in:
@@ -1684,12 +1684,12 @@ public class ReceiveCommits {
|
|||||||
if (!validCommit(changeCtl.getRefControl(), inputCommand, newCommit)) {
|
if (!validCommit(changeCtl.getRefControl(), inputCommand, newCommit)) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
rp.getRevWalk().parseBody(priorCommit);
|
||||||
|
|
||||||
// Don't allow the same tree if the commit message is unmodified
|
// Don't allow the same tree if the commit message is unmodified
|
||||||
// or no parents were updated (rebase), else warn that only part
|
// or no parents were updated (rebase), else warn that only part
|
||||||
// of the commit was modified.
|
// of the commit was modified.
|
||||||
if (newCommit.getTree() == priorCommit.getTree()) {
|
if (newCommit.getTree() == priorCommit.getTree()) {
|
||||||
rp.getRevWalk().parseBody(priorCommit);
|
|
||||||
final boolean messageEq =
|
final boolean messageEq =
|
||||||
eq(newCommit.getFullMessage(), priorCommit.getFullMessage());
|
eq(newCommit.getFullMessage(), priorCommit.getFullMessage());
|
||||||
final boolean parentsEq = parentsEqual(newCommit, priorCommit);
|
final boolean parentsEq = parentsEqual(newCommit, priorCommit);
|
||||||
|
Reference in New Issue
Block a user