Fixed bug #14097: Preview in BE opens Workspace-preview
[Packages/TYPO3.CMS.git] / t3lib / class.t3lib_tsfebeuserauth.php
index bfd73de..30e6329 100644 (file)
@@ -190,8 +190,6 @@ class t3lib_tsfeBeUserAuth extends t3lib_beUserAuth {
                if (isset($this->extAdminConfig['enable.'])) {
                        foreach($this->extAdminConfig['enable.'] as $key => $value) {
                                if ($value) {
-                                       $GLOBALS['TSFE']->includeTCA();
-
                                        $this->adminPanel = t3lib_div::makeInstance('tslib_AdminPanel');
                                        $this->extAdmEnabled = true;
 
@@ -247,7 +245,7 @@ class t3lib_tsfeBeUserAuth extends t3lib_beUserAuth {
         * @return      string.
         */
        public function displayAdminPanel() {
-               $content =  $this->adminPanel->display();
+               $content = $this->adminPanel->display();
 
                return $content;
        }
@@ -304,7 +302,7 @@ class t3lib_tsfeBeUserAuth extends t3lib_beUserAuth {
                }
 
                        // Finally a check from t3lib_beuserauth::backendCheckLogin()
-               if (!$TYPO3_CONF_VARS['BE']['adminOnly'] || $this->isAdmin()) {
+               if ($this->isUserAllowedToLogin()) {
                        return true;
                } else {
                        return false;