Uploaded image for project: 'XWiki Platform'
  1. XWiki Platform
  2. XWIKI-17000

Two concatenated separators are creating null values in list

    Details

    • Tests:
      Unit
    • Difficulty:
      Unknown
    • Documentation:
      N/A
    • Documentation in Release Notes:
      N/A
    • Similar issues:

      Description

      Default separators in Static List xobjects are " ", "," and "|", and the default behaviour before XWiki 12.0RC1 was to not consider two following separators. For example, we were able to specify list values such as

      Foo, Bar
      

      producing the values Foo and Bar, even if two separators were used.
      I don't know if this behaviour was expected or coincidental, but it existed. However we refactored the parsing of Static List as part of XWIKI-16968, and the snippet above now produces three values: Foo, null and Bar.
      The null values being produced by the fact that we got a separator, then nothing, then another separator.

      I guess that we should skip those null values to preserve the old behaviour.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                surli Simon Urli
                Reporter:
                surli Simon Urli
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: