Remove duplicate ref update commands for new change

In ReceiveCommits, the ref updates are handled together in a
BatchRefUpdate(batch.addCommand(create.cmd)), no need to add the
ReceiveCommand into the ChangeInserter.

Change-Id: Ic888248f1fec27a5f9d84afc85ac035eecfa6607
This commit is contained in:
Zhen Chen
2016-09-23 15:21:12 -07:00
parent cb51d7465a
commit f38969d6dd

View File

@@ -2012,7 +2012,6 @@ public class ReceiveCommits {
}
cmd = new ReceiveCommand(ObjectId.zeroId(), commit,
ins.getPatchSetId().toRefName());
ins.setUpdateRefCommand(cmd);
if (rp.getPushCertificate() != null) {
ins.setPushCertificate(rp.getPushCertificate().toTextWithSignature());
}
@@ -2051,7 +2050,7 @@ public class ReceiveCommits {
.setNotify(magicBranch.notify)
.setRequestScopePropagator(requestScopePropagator)
.setSendMail(true)
.setUpdateRef(true));
.setUpdateRef(false));
if (!magicBranch.hashtags.isEmpty()) {
bu.addOp(
changeId,