Polish "Remove unnecessary nesting of calls to String.format"
See gh-40494
This commit is contained in:
parent
0cf15fcad0
commit
2cb19f368e
@ -91,7 +91,8 @@ class MavenBuildOutputTimestamp {
|
|||||||
.truncatedTo(ChronoUnit.SECONDS)
|
.truncatedTo(ChronoUnit.SECONDS)
|
||||||
.toInstant();
|
.toInstant();
|
||||||
if (instant.isBefore(DATE_MIN) || instant.isAfter(DATE_MAX)) {
|
if (instant.isBefore(DATE_MIN) || instant.isAfter(DATE_MAX)) {
|
||||||
throw new IllegalArgumentException(String.format("'%s' is not within the valid range %s to %s", instant, DATE_MIN, DATE_MAX));
|
throw new IllegalArgumentException(
|
||||||
|
String.format("'%s' is not within the valid range %s to %s", instant, DATE_MIN, DATE_MAX));
|
||||||
}
|
}
|
||||||
return instant;
|
return instant;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user