Uploaded image for project: 'Struts 2'
  1. Struts 2
  2. WW-3154

RepopulateConversionErrorFieldValidatorSupport logs a warning when repopulating fields without conversion errors

VotersWatch issueWatchersLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.1.2
    • Fix Version/s: 2.1.8
    • Component/s: None
    • Labels:
      None
    • Environment:

      Tomcat 6.0.18 on CentOS 4

      Description

      In RepopulateConversionErrorFieldValidatorSupport at line 176 (in the 2.1.2 version at least), a warning is logged on any field that does not have a conversion error.

      The call to "conversionErrors.get(fullFieldName)" returns null when there was no errors, and therefore the result of that call fails to match the instanceof checks, falling through to the else clause and logging the error.

      There should be no log message when there is no conversion error as the repopulate function has nothing it needs to do in that case. I would suggest a "conversionErrors.contains(fullFieldName)" prior to doing anything in that method. Or, change the validate() method to test for that before calling the repopulateField() method.

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              lucasn Lucas Nelson

              Dates

              • Created:
                Updated:
                Resolved:

                Issue deployment