Skip to content

Commit 2cb19f3

Browse files
committed
Polish "Remove unnecessary nesting of calls to String.format"
See gh-40494
1 parent 0cf15fc commit 2cb19f3

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

spring-boot-project/spring-boot-tools/spring-boot-maven-plugin/src/main/java/org/springframework/boot/maven/MavenBuildOutputTimestamp.java

+2-1
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,8 @@ Instant toInstant() {
9191
.truncatedTo(ChronoUnit.SECONDS)
9292
.toInstant();
9393
if (instant.isBefore(DATE_MIN) || instant.isAfter(DATE_MAX)) {
94-
throw new IllegalArgumentException(String.format("'%s' is not within the valid range %s to %s", instant, DATE_MIN, DATE_MAX));
94+
throw new IllegalArgumentException(
95+
String.format("'%s' is not within the valid range %s to %s", instant, DATE_MIN, DATE_MAX));
9596
}
9697
return instant;
9798
}

0 commit comments

Comments
 (0)