Controller/MailController.php
private function swiftEventFilter(TranslatorInterface $translator, $event): string
    {
        switch ($event) {
            case \Swift_Events_SendEvent::RESULT_SUCCESS:
                return $translator->trans('RESULT_SUCCESS');
            case \Swift_Events_SendEvent::RESULT_FAILED:
                return $translator->trans('RESULT_FAILED');
            case \Swift_Events_SendEvent::RESULT_SPOOLED:
                return $translator->trans('RESULT_SPOOLED');
            case \Swift_Events_SendEvent::RESULT_PENDING:
                return $translator->trans('RESULT_PENDING');
            case \Swift_Events_SendEvent::RESULT_TENTATIVE:
                return $translator->trans('RESULT_TENTATIVE');
            case -1:
                return $translator->trans('RESULT_DELETED');
        }

        return '';
    }
private function swiftEventFilter(TranslatorInterface $translator, $event): string
    {
        switch ($event) {
            case \Swift_Events_SendEvent::RESULT_SUCCESS:
                return $translator->trans('RESULT_SUCCESS');
            case \Swift_Events_SendEvent::RESULT_FAILED:
                return $translator->trans('RESULT_FAILED');
            case \Swift_Events_SendEvent::RESULT_SPOOLED:
                return $translator->trans('RESULT_SPOOLED');
            case \Swift_Events_SendEvent::RESULT_PENDING:
                return $translator->trans('RESULT_PENDING');
            case \Swift_Events_SendEvent::RESULT_TENTATIVE:
                return $translator->trans('RESULT_TENTATIVE');
            case -1:
                return $translator->trans('RESULT_DELETED');
        }

        return '';
    }
private function swiftEventFilter ( TranslatorInterface $ translator , $ event ) : string { switch ( $ event ) { case \ Swift_Events_SendEvent :: RESULT_SUCCESS : return $ translator -> trans ( 'RESULT_SUCCESS' ) ; case \ Swift_Events_SendEvent :: RESULT_FAILED : return $ translator -> trans ( 'RESULT_FAILED' ) ; case \ Swift_Events_SendEvent :: RESULT_SPOOLED : return $ translator -> trans ( 'RESULT_SPOOLED' ) ; case \ Swift_Events_SendEvent :: RESULT_PENDING : return $ translator -> trans ( 'RESULT_PENDING' ) ; case \ Swift_Events_SendEvent :: RESULT_TENTATIVE : return $ translator -> trans ( 'RESULT_TENTATIVE' ) ; case - 1 : return $ translator -> trans ( 'RESULT_DELETED' ) ; } return '' ; }
Swift Event.

@param $event

@return string
Swift Event .