Fix broken CommandItems logic.