Uploaded image for project: 'Magnolia'
  1. Magnolia
  2. MAGNOLIA-6719

Map2Bean should always interpret map keys as Strings

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Won't Do
    • Icon: Neutral Neutral
    • None
    • 5.4.7
    • None
    • None

      At least in the case of imaging variations in a theme, and probably in other cases, when a key in a YAML file is interpretable as an integer (such as 5 or 256 or 400) Map2Bean stores it as an integer instead of a String. This can cause problems in other code which attempts to match a string value to find a specific item in a map.

      For example, this problem occurs when the variation resolver takes the string name of an imaging variation, such as "400" and tries to find a matching imaging variation in a theme - currently it fails because the key in the YAML definition was interpreted as an integer.

      Note that definitions provided by JCR with numbers as key work correctly. This is used in the travel-demo-theme.

        Acceptance criteria

              Unassigned Unassigned
              czimmermann Christopher Zimmermann
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved:

                  Bug DoR
                  Task DoD