Code Duplication    Length = 7-8 lines in 6 locations

typo3/sysext/backend/Classes/Module/BaseScriptClass.php 1 location

@@ 378-385 (lines=8) @@
375
    /**
376
     * @return PageRenderer
377
     */
378
    protected function getPageRenderer()
379
    {
380
        if ($this->pageRenderer === null) {
381
            $this->pageRenderer = GeneralUtility::makeInstance(PageRenderer::class);
382
        }
383
384
        return $this->pageRenderer;
385
    }
386
}
387

typo3/sysext/backend/Classes/Module/AbstractFunctionModule.php 1 location

@@ 209-216 (lines=8) @@
206
    /**
207
     * @return PageRenderer
208
     */
209
    protected function getPageRenderer()
210
    {
211
        if ($this->pageRenderer === null) {
212
            $this->pageRenderer = GeneralUtility::makeInstance(PageRenderer::class);
213
        }
214
215
        return $this->pageRenderer;
216
    }
217
}
218

typo3/sysext/frontend/Classes/Controller/TypoScriptFrontendController.php 1 location

@@ 821-828 (lines=8) @@
818
    /**
819
     * Initializes the page renderer object
820
     */
821
    protected function initPageRenderer()
822
    {
823
        if ($this->pageRenderer !== null) {
824
            return;
825
        }
826
        $this->pageRenderer = GeneralUtility::makeInstance(PageRenderer::class);
827
        $this->pageRenderer->setTemplateFile('EXT:frontend/Resources/Private/Templates/MainPage.html');
828
    }
829
830
    /**
831
     * @param string $contentType

typo3/sysext/backend/Classes/Form/FormResultCompiler.php 1 location

@@ 314-320 (lines=7) @@
311
     *
312
     * @return \TYPO3\CMS\Core\Page\PageRenderer
313
     */
314
    protected function getPageRenderer()
315
    {
316
        if ($this->pageRenderer === null) {
317
            $this->pageRenderer = GeneralUtility::makeInstance(PageRenderer::class);
318
        }
319
        return $this->pageRenderer;
320
    }
321
}
322

typo3/sysext/recordlist/Classes/Controller/ElementBrowserFramesetController.php 1 location

@@ 127-134 (lines=8) @@
124
    /**
125
     * @return PageRenderer
126
     */
127
    protected function getPageRenderer()
128
    {
129
        if ($this->pageRenderer === null) {
130
            $this->pageRenderer = GeneralUtility::makeInstance(PageRenderer::class);
131
        }
132
133
        return $this->pageRenderer;
134
    }
135
}
136

typo3/sysext/recordlist/Classes/RecordList.php 1 location

@@ 768-775 (lines=8) @@
765
    /**
766
     * @return PageRenderer
767
     */
768
    protected function getPageRenderer()
769
    {
770
        if ($this->pageRenderer === null) {
771
            $this->pageRenderer = GeneralUtility::makeInstance(PageRenderer::class);
772
        }
773
774
        return $this->pageRenderer;
775
    }
776
}
777