Classes/ExtMgm/Statefield.php
protected function addFlashMessage(FlashMessage $flashMessage)
    {
        if (!($this->flashMessageService instanceof FlashMessageService)) {
            $this->flashMessageService = GeneralUtility::makeInstance(FlashMessageService::class);
        }
        /** @var $defaultFlashMessageQueue \TYPO3\CMS\Core\Messaging\FlashMessageQueue */
        $defaultFlashMessageQueue = $this->flashMessageService->getMessageQueueByIdentifier();
        $defaultFlashMessageQueue->enqueue($flashMessage);
    }
protected function addFlashMessage(FlashMessage $flashMessage)
    {
        if (!($this->flashMessageService instanceof FlashMessageService)) {
            $this->flashMessageService = GeneralUtility::makeInstance(FlashMessageService::class);
        }
        /** @var $defaultFlashMessageQueue \TYPO3\CMS\Core\Messaging\FlashMessageQueue */
        $defaultFlashMessageQueue = $this->flashMessageService->getMessageQueueByIdentifier();
        $defaultFlashMessageQueue->enqueue($flashMessage);
    }
protected function addFlashMessage ( FlashMessage $ flashMessage ) { if ( ! ( $ this -> flashMessageService instanceof FlashMessageService ) ) { $ this -> flashMessageService = GeneralUtility :: makeInstance ( FlashMessageService :: class ) ; } /** @var $defaultFlashMessageQueue \TYPO3\CMS\Core\Messaging\FlashMessageQueue */ $ defaultFlashMessageQueue = $ this -> flashMessageService -> getMessageQueueByIdentifier ( ) ; $ defaultFlashMessageQueue -> enqueue ( $ flashMessage ) ; }
Add flash message to message queue

@param FlashMessage $flashMessage
@return void
Add flash message to message queue