← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 2271: Fix bug: User setting is throwing exception.

 

------------------------------------------------------------
revno: 2271
committer: Tran Chau <tran.hispvietnam@xxxxxxxxx>
branch nick: trunk
timestamp: Wed 2010-09-29 15:28:47 +0700
message:
  Fix bug: User setting is throwing exception.
modified:
  dhis-2/dhis-services/dhis-service-i18n/src/main/java/org/hisp/dhis/i18n/resourcebundle/DefaultResourceBundleManager.java


--
lp:dhis2
https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk

Your team DHIS 2 developers is subscribed to branch lp:dhis2.
To unsubscribe from this branch go to https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk/+edit-subscription
=== modified file 'dhis-2/dhis-services/dhis-service-i18n/src/main/java/org/hisp/dhis/i18n/resourcebundle/DefaultResourceBundleManager.java'
--- dhis-2/dhis-services/dhis-service-i18n/src/main/java/org/hisp/dhis/i18n/resourcebundle/DefaultResourceBundleManager.java	2010-09-23 04:50:45 +0000
+++ dhis-2/dhis-services/dhis-service-i18n/src/main/java/org/hisp/dhis/i18n/resourcebundle/DefaultResourceBundleManager.java	2010-09-29 08:28:47 +0000
@@ -174,14 +174,13 @@
 
     private Collection<Locale> getAvailableLocalesFromDir( String dirPath )
     {
-        File dir = new File( dirPath );
-        
+        dirPath = dirPath.replaceAll( "%20", " " );
+        File dir = new File( dirPath );    
         Set<Locale> availableLocales = new HashSet<Locale>();
-
         File[] files = dir.listFiles( new FilenameFilter()
         {
             public boolean accept( File dir, String name )
-            {
+            {             
                 return name.startsWith( globalResourceBundleName ) && name.endsWith( EXT_RESOURCE_BUNDLE );
             }
         } );