Refactored display actions for both lists and tasks

After the addition of waitForResponse, the logic to display actions was
a little bit odd.