Skip to content

Commit 6d7d7d9

Browse files
committed
fix toUpperCase without locale call
1 parent 25be2bb commit 6d7d7d9

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

spring-boot-project/spring-boot/src/main/java/org/springframework/boot/context/config/StandardConfigDataReference.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@
1616

1717
package org.springframework.boot.context.config;
1818

19+
import java.util.Locale;
20+
1921
import org.springframework.boot.env.PropertySourceLoader;
2022
import org.springframework.util.StringUtils;
2123

@@ -52,7 +54,7 @@ class StandardConfigDataReference {
5254
String extension, PropertySourceLoader propertySourceLoader) {
5355
this.configDataLocation = configDataLocation;
5456
String profileSuffix = (StringUtils.hasText(profile))
55-
? root.startsWith("env:") ? "_" + profile.toUpperCase() : "-" + profile : "";
57+
? root.startsWith("env:") ? "_" + profile.toUpperCase(Locale.ROOT) : "-" + profile : "";
5658
this.resourceLocation = root + profileSuffix + ((extension != null) ? "." + extension : "");
5759
this.directory = directory;
5860
this.profile = profile;

0 commit comments

Comments
 (0)