[Yanel-commits] rev 32616 - public/yanel/trunk/src/impl/java/org/wyona/yanel/impl/resources

josias at wyona.com josias at wyona.com
Thu Feb 28 10:02:13 CET 2008


Author: josias
Date: 2008-02-28 10:02:12 +0100 (Thu, 28 Feb 2008)
New Revision: 32616

Modified:
   public/yanel/trunk/src/impl/java/org/wyona/yanel/impl/resources/BasicXMLResource.java
Log:
avoid npe if rti is used instead of rc and i18n-catalogue property is not set

Modified: public/yanel/trunk/src/impl/java/org/wyona/yanel/impl/resources/BasicXMLResource.java
===================================================================
--- public/yanel/trunk/src/impl/java/org/wyona/yanel/impl/resources/BasicXMLResource.java	2008-02-28 09:02:11 UTC (rev 32615)
+++ public/yanel/trunk/src/impl/java/org/wyona/yanel/impl/resources/BasicXMLResource.java	2008-02-28 09:02:12 UTC (rev 32616)
@@ -346,8 +346,10 @@
     protected String[] getI18NCatalogueNames() throws Exception {
         ArrayList catalogues = new ArrayList();
         String[] rcCatalogues = getResourceConfigProperties("i18n-catalogue");
-        for (int i = 0; i < rcCatalogues.length; i++) {
-            catalogues.add(rcCatalogues[i]);
+        if (rcCatalogues != null) {
+            for (int i = 0; i < rcCatalogues.length; i++) {
+                catalogues.add(rcCatalogues[i]);
+            }
         }
         String realmCatalogue = getRealm().getI18nCatalogue();
         if (realmCatalogue != null) {



More information about the Yanel-commits mailing list