src/PHPDish/Bundle/ForumBundle/Twig/TopicExtension.php
public function getFunctions(): array
    {
        return [
            new \Twig_SimpleFunction('get_thread', [$this->threadManager, 'findThreadById']),
            new \Twig_SimpleFunction('get_thread_by_slug', [$this->threadManager, 'findThreadBySlug']),
            new \Twig_SimpleFunction('get_threads', [$this, 'getThreads']),
            new \Twig_SimpleFunction('get_threads_pager', [$this->threadManager, 'findThreadsPager']),

            new \Twig_SimpleFunction('get_topic', [$this->topicManager, 'findTopicById']),
            new \Twig_SimpleFunction('get_topics', [$this, 'getTopics']),
            new \Twig_SimpleFunction('get_topics_pager', [$this->topicManager, 'findTopicsPager']),
            new \Twig_SimpleFunction('get_topics_pager_by_thread', [$this->topicManager, 'findThreadTopics']),

            new \Twig_SimpleFunction('get_reply', [$this->replyManager, 'findReplyById']),
            new \Twig_SimpleFunction('get_replies', [$this, 'getReplies']),
            new \Twig_SimpleFunction('get_replies_pager', [$this->replyManager, 'findRepliesPager']),
        ];
    }
public function getFunctions(): array
    {
        return [
            new \Twig_SimpleFunction('get_thread', [$this->threadManager, 'findThreadById']),
            new \Twig_SimpleFunction('get_thread_by_slug', [$this->threadManager, 'findThreadBySlug']),
            new \Twig_SimpleFunction('get_threads', [$this, 'getThreads']),
            new \Twig_SimpleFunction('get_threads_pager', [$this->threadManager, 'findThreadsPager']),

            new \Twig_SimpleFunction('get_topic', [$this->topicManager, 'findTopicById']),
            new \Twig_SimpleFunction('get_topics', [$this, 'getTopics']),
            new \Twig_SimpleFunction('get_topics_pager', [$this->topicManager, 'findTopicsPager']),
            new \Twig_SimpleFunction('get_topics_pager_by_thread', [$this->topicManager, 'findThreadTopics']),

            new \Twig_SimpleFunction('get_reply', [$this->replyManager, 'findReplyById']),
            new \Twig_SimpleFunction('get_replies', [$this, 'getReplies']),
            new \Twig_SimpleFunction('get_replies_pager', [$this->replyManager, 'findRepliesPager']),
        ];
    }
{@inheritdoc}