From 065e50a444a00d496e153243a4bdbc03753ff754 Mon Sep 17 00:00:00 2001 From: Sam Brannen <104798+sbrannen@users.noreply.github.com> Date: Sun, 11 May 2025 15:44:41 +0200 Subject: [PATCH] Override containsProperty() in FallbackEnvironmentPropertySource This commit overrides containsProperty() in FallbackEnvironmentPropertySource for consistency with the implementation of ConfigurableEnvironmentPropertySource. See gh-34861 --- .../support/PropertySourcesPlaceholderConfigurer.java | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/spring-context/src/main/java/org/springframework/context/support/PropertySourcesPlaceholderConfigurer.java b/spring-context/src/main/java/org/springframework/context/support/PropertySourcesPlaceholderConfigurer.java index 4e023ab985..2686ba5764 100644 --- a/spring-context/src/main/java/org/springframework/context/support/PropertySourcesPlaceholderConfigurer.java +++ b/spring-context/src/main/java/org/springframework/context/support/PropertySourcesPlaceholderConfigurer.java @@ -279,6 +279,11 @@ public class PropertySourcesPlaceholderConfigurer extends PlaceholderConfigurerS return super.source.getProperty(name); } + @Override + public boolean containsProperty(String name) { + return super.source.containsProperty(name); + } + @Override public String toString() { return "FallbackEnvironmentPropertySource {environment=" + super.source + "}";