Why is Contents aka @@folder-contents available in the toolbar for non-folderish content like a Document? Contents only makes sense when your object is folderish in order to get the listing of the contained items. The current behavior is to get a listing of the parent object ... this is not intuitive and beyond user's experience and expectation.
My guestimate is that it's a choice between two evils. Because it is a 'main' button in the toolbar, if you would show/remove it based on a condition, all other menu items would shift up and be moved in the UI, best practice UX is to keep icons/buttons positions stable at all times.
If you want to disable it should still be visible but greyed out or other visual hints that it is disabled on this particular context, but that's not default portal_actions functionality.