Uploaded image for project: 'OpenMRS Core'
  1. OpenMRS Core
  2. TRUNK-5564

PersonAddressValidator - Throws exception instead of logging

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Code Review (Initial)
    • Priority: Non-Essential
    • Resolution: Unresolved
    • Affects Version/s: Core 2.2.0
    • Fix Version/s: Platform 2.2.0, Core 2.2.0
    • Component/s: None
    • Labels:
      None
    • Complexity:
      Low
    • Development:

      Description

      The PersonAddressValidator Constructor throws an exception when a null value is assigned to the argument.

       

      That is different to the PersonNameValidator behaviour that does just log the error and avoids to throw an exception: https://github.com/openmrs/openmrs-core/blob/master/api/src/main/java/org/openmrs/validator/PersonNameValidator.java#L59

       

      My assumptions would be that validators should deal in the same way with the null values. Hence the PersonAddressValidator should be coded in a way that avoids throwing exceptions.

       

      Relates to: https://issues.openmrs.org/browse/TRUNK-5473

        Gliffy Diagrams

          Attachments

            Activity

              People

              Assignee:
              achilep Pahonsi Bebeto Achile
              Reporter:
              fruether Fred Rue
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Dates

                Created:
                Updated: