Uploaded image for project: 'Magnolia Personalization'
  1. Magnolia Personalization
  2. MGNLPN-480

Delete action should not be available when no item is selected

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Cannot Reproduce
    • Icon: Neutral Neutral
    • None
    • None
    • Personas App
    • None

      Under some specific circumstances the delete action becomes available even though no item is selected.

      Steps to reproduce

      With Personas app freshly started: * Add persona, then Cancel from footer (important!)

      • back in browser, Action bar is displayed for Multiple items, despite nothing selected
      • (hitting Delete items apparently attempts to delete the root)

      Expected behaviour

      Only the default items should be available from the action bar (those that are shown when the app is initially started).

      Initial analysis

      After cancelling the add persona action DefaultAvailabilityChecker#isAvailable(List<T>) receives a list with the workspace root as its only item. However, later one the code relies on List.isEmpty to special case the root handling, which is skipped in this situation.

      Also the segment app shows similar issues and I strongly suspect there is a common root cause. We probable need to migrate this issue once we have a better understanding. 
       

      cc mgeljic

        Acceptance criteria

              Unassigned Unassigned
              mduerig Michael Duerig
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved:

                  Bug DoR
                  Task DoD