Uploaded image for project: 'Hippo Site Toolkit 2'
  1. Hippo Site Toolkit 2
  2. HSTTWO-3693

[Backport 3.2] LocationMapTreeComponentDocuments#add2LocationMap throws NPE when sitemap parameters object contains a null key or value

    Details

    • Type: Bug
    • Status: Closed
    • Priority: High
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 3.2.2
    • Component/s: None
    • Labels:
      None
    • Similar issues:
    • Sprint:
      Platform sprint 131
    • Processed by team:
      Platform

      Description

      The problem:
      In HstSiteMapItemService parameters are stored in a HashMap : A HashMap allows null as key or value
      In LocationMapTreeComponentDocuments an iteration through HstSiteMapItemService parameters is done as follows:

      final Properties siteMapItemParameters = new Properties();
      for (Map.Entry<String, String> param : siteMapItem.getParameters().entrySet()) {
          siteMapItemParameters.put(param.getKey(), param.getValue());
      }
      

      problem now is that Properties is a subclass op Hashtable which does throw an NPE on a null key or value.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                aschrijvers Ard Schrijvers
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: