getOrder()->getStatusHistoryCollection() ->addFieldToFilter('status', OrderStatus::rejected->name); if ($collection->getSize()) { return $collection->getFirstItem()->getComment(); } return ''; } }