Pluto
  1. Pluto
  2. PLUTO-609

PortletPreferencesImpl doesn't handle null preferences correctly

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 2.0.2
    • Fix Version/s: 2.0.3, 2.1.0-M3, 2.1.0
    • Component/s: None
    • Labels:
      None

      Description

      PLT.17.1 states "Preference attributes are String array objects. Preferences attributes can be set to null." In Pluto if you call PortletPreference.setValue("name", null), PortletPreference.setValues("name", String[]

      {null}

      ), or PortletPreference.setValues("name", null) the correct data is passed to the underlying preference storage SPI.

      The problem is when calling getValue("name", "DEFAULT") or getValues("name", new String[]

      { "DEFAULT" }

      ) for any of the three previous cases "DEFAULT" is returned. From my reading of the spec this is not correct as in each case the preference has been set but with a single null value or a null values array.

        Activity

        Eric Dalquist created issue -
        Eric Dalquist made changes -
        Field Original Value New Value
        Status Open [ 1 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        Ate Douma made changes -
        Resolution Fixed [ 1 ]
        Status Resolved [ 5 ] Reopened [ 4 ]
        Assignee Eric Dalquist [ edalquist ] Ate Douma [ adouma ]
        Ate Douma made changes -
        Status Reopened [ 4 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        Eric Dalquist made changes -
        Fix Version/s 2.1.0-M3 [ 12323147 ]

          People

          • Assignee:
            Ate Douma
            Reporter:
            Eric Dalquist
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development