Author: adrianc
Date: Mon Dec 1 07:53:13 2008
New Revision: 722104
URL:
http://svn.apache.org/viewvc?rev=722104&view=revLog:
Fixed bug where properties using the ${} syntax weren't being expanded, reported by Mridul Pathak -
https://issues.apache.org/jira/browse/OFBIZ-2066.
Modified:
ofbiz/trunk/framework/base/src/org/ofbiz/base/util/string/FlexibleStringExpander.java
Modified: ofbiz/trunk/framework/base/src/org/ofbiz/base/util/string/FlexibleStringExpander.java
URL:
http://svn.apache.org/viewvc/ofbiz/trunk/framework/base/src/org/ofbiz/base/util/string/FlexibleStringExpander.java?rev=722104&r1=722103&r2=722104&view=diff==============================================================================
--- ofbiz/trunk/framework/base/src/org/ofbiz/base/util/string/FlexibleStringExpander.java (original)
+++ ofbiz/trunk/framework/base/src/org/ofbiz/base/util/string/FlexibleStringExpander.java Mon Dec 1 07:53:13 2008
@@ -363,6 +363,12 @@
}
public void append(StringBuilder buffer, Map<String, ? extends Object> context, TimeZone timeZone, Locale locale) {
Object obj = this.fma.get(context, locale);
+ if (obj == null) {
+ String key = fma.getOriginalName();
+ if (key.startsWith("env.")) {
+ obj = System.getProperty(key.substring(4));
+ }
+ }
if (obj != null) {
try {
buffer.append((String) ObjectType.simpleTypeConvert(obj, "String", null, timeZone, locale, true));