ReceiveCommits: drop superfluous check for writable project
We check for writable project state on entry into the class. Change-Id: I75956313a16c243a06915161f6938244989b670a
This commit is contained in:
@@ -1651,10 +1651,6 @@ class ReceiveCommits {
|
||||
rejectProhibited(cmd, err.get());
|
||||
return;
|
||||
}
|
||||
if (!projectState.statePermitsWrite()) {
|
||||
reject(cmd, "project state does not permit write");
|
||||
return;
|
||||
}
|
||||
|
||||
// TODO(davido): Remove legacy support for drafts magic branch option
|
||||
// after repo-tool supports private and work-in-progress changes.
|
||||
@@ -2548,10 +2544,6 @@ class ReceiveCommits {
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!projectState.statePermitsWrite()) {
|
||||
reject(inputCommand, "cannot add patch set to " + ontoChange + ".");
|
||||
return false;
|
||||
}
|
||||
if (change.getStatus().isClosed()) {
|
||||
reject(inputCommand, "change " + ontoChange + " closed");
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user