mirror of
https://github.com/google/nomulus
synced 2026-01-09 15:43:52 +00:00
Add debug string on checkArgument failure
------------- Created by MOE: https://github.com/google/moe MOE_MIGRATED_REVID=184838852
This commit is contained in:
@@ -271,7 +271,11 @@ abstract class CreateOrUpdateTldCommand extends MutatingCommand {
|
||||
checkArgument(roidSuffix == null || tlds.size() == 1,
|
||||
"Can't update roid suffixes on multiple TLDs simultaneously");
|
||||
for (String tld : tlds) {
|
||||
checkArgument(tld.equals(canonicalizeDomainName(tld)));
|
||||
checkArgument(
|
||||
tld.equals(canonicalizeDomainName(tld)),
|
||||
"TLD '%s' should be given in the canonical form '%s'",
|
||||
tld,
|
||||
canonicalizeDomainName(tld));
|
||||
checkArgument(
|
||||
!CharMatcher.javaDigit().matches(tld.charAt(0)),
|
||||
"TLDs cannot begin with a number");
|
||||
|
||||
Reference in New Issue
Block a user