src/Controller/Ajax.php
protected function exitScript()
    {
        // @codingStandardsIgnoreStart
        @\trigger_error('Use own response exit!', E_USER_DEPRECATED);
        // @codingStandardsIgnoreEnd

        $session    = System::getContainer()->get('session');
        $sessionBag = $session->getBag('contao_backend')->all();

        $user = BackendUser::getInstance();

        Database::getInstance()->prepare('UPDATE tl_user SET tl_user.session=? WHERE tl_user.id=?')
            ->execute(\serialize($sessionBag), $user->id);

        exit;
    }
protected function exitScript()
    {
        // @codingStandardsIgnoreStart
        @\trigger_error('Use own response exit!', E_USER_DEPRECATED);
        // @codingStandardsIgnoreEnd

        $session    = System::getContainer()->get('session');
        $sessionBag = $session->getBag('contao_backend')->all();

        $user = BackendUser::getInstance();

        Database::getInstance()->prepare('UPDATE tl_user SET tl_user.session=? WHERE tl_user.id=?')
            ->execute(\serialize($sessionBag), $user->id);

        exit;
    }
protected function exitScript ( ) { // @codingStandardsIgnoreStart @ \ trigger_error ( 'Use own response exit!' , E_USER_DEPRECATED ) ; // @codingStandardsIgnoreEnd $ session = System :: getContainer ( ) -> get ( 'session' ) ; $ sessionBag = $ session -> getBag ( 'contao_backend' ) -> all ( ) ; $ user = BackendUser :: getInstance ( ) ; Database :: getInstance ( ) -> prepare ( 'UPDATE tl_user SET tl_user.session=? WHERE tl_user.id=?' ) -> execute ( \ serialize ( $ sessionBag ) , $ user -> id ) ; exit ; }
Convenience method to exit the script.

Will get called from subclasses to have a central endpoint to exit the script.

@return void

@deprecated Deperecated since 2.1 and where remove in 3.0. Use own response exit.

@SuppressWarnings(PHPMD.ExitExpression) - The whole purpose of the method is the exit expression.
Convenience method to exit the script .