[FEATURE] Add public API to get ApplicationContext
[Packages/TYPO3.CMS.git] / typo3 / sysext / core / Classes / Core / Bootstrap.php
index 27f8af5..ea152fa 100644 (file)
@@ -112,6 +112,7 @@ class Bootstrap {
         * Returns the context this bootstrap was started in.
         *
         * @return \TYPO3\CMS\Core\Core\ApplicationContext The context encapsulated in an object
+        * @internal This is not a public API method, do not use in own extensions. Use \TYPO3\CMS\Core\Utility\GeneralUtility::getContext() instead
         */
        public function getContext() {
                return $this->context;
@@ -141,6 +142,7 @@ class Bootstrap {
         */
        public function baseSetup($relativePathPart = '') {
                \TYPO3\CMS\Core\Core\SystemEnvironmentBuilder::run($relativePathPart);
+               Utility\GeneralUtility::presetContext($this->context);
                return $this;
        }