From ee50d849a195a52328444e88769bdb481c03f541 Mon Sep 17 00:00:00 2001 From: Juergen Hoeller Date: Wed, 31 Oct 2012 02:19:23 +0100 Subject: [PATCH] Polished "Could not resolve placeholder" error message --- .../org/springframework/util/PropertyPlaceholderHelper.java | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/spring-core/src/main/java/org/springframework/util/PropertyPlaceholderHelper.java b/spring-core/src/main/java/org/springframework/util/PropertyPlaceholderHelper.java index 0bea53ea6a..df814691d8 100644 --- a/spring-core/src/main/java/org/springframework/util/PropertyPlaceholderHelper.java +++ b/spring-core/src/main/java/org/springframework/util/PropertyPlaceholderHelper.java @@ -142,7 +142,6 @@ public class PropertyPlaceholderHelper { } // Recursive invocation, parsing placeholders contained in the placeholder key. placeholder = parseStringValue(placeholder, placeholderResolver, visitedPlaceholders); - // Now obtain the value for the fully resolved key... String propVal = placeholderResolver.resolvePlaceholder(placeholder); if (propVal == null && this.valueSeparator != null) { @@ -172,9 +171,8 @@ public class PropertyPlaceholderHelper { } else { throw new IllegalArgumentException("Could not resolve placeholder '" + - placeholder + "'" + " in string value [" + strVal + "]"); + placeholder + "'" + " in string value \"" + strVal + "\""); } - visitedPlaceholders.remove(originalPlaceholder); } else {