mirror of
https://github.com/scm-manager/scm-manager.git
synced 2026-03-06 12:20:56 +01:00
Fix preconditions
This commit is contained in:
@@ -115,7 +115,7 @@ public class ModifyCommandBuilder {
|
||||
*/
|
||||
public String execute() {
|
||||
try {
|
||||
Preconditions.checkArgument(request.isValid(), "commit message, author and branch are required");
|
||||
Preconditions.checkArgument(request.isValid(), "commit message, branch and at least one request are required");
|
||||
return command.execute(request);
|
||||
} finally {
|
||||
try {
|
||||
|
||||
@@ -65,7 +65,7 @@ public class ModifyCommandRequest implements Resetable, Validateable {
|
||||
|
||||
@Override
|
||||
public boolean isValid() {
|
||||
return StringUtils.isNotEmpty(commitMessage) && StringUtils.isNotEmpty(branch) && author != null && !requests.isEmpty();
|
||||
return StringUtils.isNotEmpty(commitMessage) && StringUtils.isNotEmpty(branch) && !requests.isEmpty();
|
||||
}
|
||||
|
||||
public interface PartialRequest {
|
||||
|
||||
Reference in New Issue
Block a user