Commits

Anonymous committed 29497a5

XWorkConverter: unknownMappings is out of sync with defaultMappings

Issue Number: XW-550
Submitted by: Lukasz Racon

git-svn-id: http://svn.opensymphony.com/svn/xwork/trunk@1641e221344d-f017-0410-9bd5-d282ab1896d7

Comments (0)

Files changed (1)

src/java/com/opensymphony/xwork2/conversion/impl/XWorkConverter.java

      * @return a TypeConverter to handle the specified class or null if none can be found
      */
     public TypeConverter lookup(String className) {
-        if (unknownMappings.contains(className)) {
+        if (unknownMappings.contains(className) && !defaultMappings.containsKey(className)) {
             return null;
         }
 
 
     public synchronized void registerConverter(String className, TypeConverter converter) {
         defaultMappings.put(className, converter);
+        if ( unknownMappings.contains(className)) {
+            unknownMappings.remove(className);
+        }
     }
 
     public synchronized void registerConverterNotFound(String className) {