Author: keith
Date: Tue Jul 29 05:18:11 2008
New Revision: 20106
URL: http://wso2.org/svn/browse/wso2?view=rev&revision=20106

Log:
Attempting to fix Mashup-962


Modified:
   trunk/mashup/java/modules/core/src/org/wso2/mashup/utils/MashupUtils.java

Modified: 
trunk/mashup/java/modules/core/src/org/wso2/mashup/utils/MashupUtils.java
URL: 
http://wso2.org/svn/browse/wso2/trunk/mashup/java/modules/core/src/org/wso2/mashup/utils/MashupUtils.java?rev=20106&r1=20105&r2=20106&view=diff
==============================================================================
--- trunk/mashup/java/modules/core/src/org/wso2/mashup/utils/MashupUtils.java   
(original)
+++ trunk/mashup/java/modules/core/src/org/wso2/mashup/utils/MashupUtils.java   
Tue Jul 29 05:18:11 2008
@@ -987,14 +987,14 @@
 
                 Hashtable faulties = 
configContext.getAxisConfiguration().getFaultyServices();
 
-                Iterator iterator = faulties.keySet().iterator();
-
-                while (iterator.hasNext()) {
-                    if (iterator.next().equals(file.getAbsolutePath())) {
-                        faulties.remove(file.getAbsolutePath());
-                        // Removing from the registry
-                        userRegistry.delete(inferPathFromFileName(username, 
file.getName()));
-                    }
+                boolean found = false;
+                if (faulties.containsKey(file.getAbsolutePath())) {
+                    found = true;
+                    // Removing from the registry
+                    userRegistry.delete(inferPathFromFileName(username, 
file.getName()));
+                }
+                if (found) {
+                   faulties.remove(file.getAbsolutePath()); 
                 }
             } catch (NullPointerException e) {
                 // Sometimes at the very first startup a NPE is thrown 
swallowing it since it cures itself in the next startup

_______________________________________________
Mashup-dev mailing list
[email protected]
http://wso2.org/cgi-bin/mailman/listinfo/mashup-dev

Reply via email to