ofbiz-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lekt...@apache.org
Subject svn commit: r607848 - /ofbiz/trunk/framework/base/src/base/org/ofbiz/base/util/UtilProperties.java
Date Tue, 01 Jan 2008 14:08:08 GMT
Author: lektran
Date: Tue Jan  1 06:08:07 2008
New Revision: 607848

URL: http://svn.apache.org/viewvc?rev=607848&view=rev
Log:
Fixed a problem when a property isn't found in the bundle, the bundle throws an exception
which wasn't being caught.  Reported by Chris Lombardi in the user list

Modified:
    ofbiz/trunk/framework/base/src/base/org/ofbiz/base/util/UtilProperties.java

Modified: ofbiz/trunk/framework/base/src/base/org/ofbiz/base/util/UtilProperties.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/base/src/base/org/ofbiz/base/util/UtilProperties.java?rev=607848&r1=607847&r2=607848&view=diff
==============================================================================
--- ofbiz/trunk/framework/base/src/base/org/ofbiz/base/util/UtilProperties.java (original)
+++ ofbiz/trunk/framework/base/src/base/org/ofbiz/base/util/UtilProperties.java Tue Jan  1
06:08:07 2008
@@ -381,7 +381,12 @@
 
         if (bundle == null) return "";
 
-        String value = (String) bundle.getString(name);
+        String value = null;
+        try {
+            value = (String)bundle.getString(name);
+        } catch (Exception e) {
+            Debug.log(e.getMessage(), module);
+        }
         return value == null ? "" : value.trim();
     }
 



Mime
View raw message