Project

General

Profile

Actions

Bug #20523

closed

Turning off the admin-panel results in error

Added by Niels Fröhling over 15 years ago. Updated over 14 years ago.

Status:
Closed
Priority:
Should have
Category:
-
Target version:
-
Start date:
2009-05-29
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
4.3
PHP Version:
5.2
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

Turning off the admin-panel (it's a 'admin' BE-user with adminPanel = 0 in the user's TS-config) results in error when using the Web->View:

Fatal error: Call to a member function display() on a non-object in /var/www/typo3-svn-semantic/t3lib/class.t3lib_tsfebeuserauth.php on line 251

(issue imported from #M11212)


Files

11212_v1.diff (571 Bytes) 11212_v1.diff Administrator Admin, 2009-05-30 12:43
11212_v2.diff (463 Bytes) 11212_v2.diff Administrator Admin, 2009-08-22 16:15
0011212_v3.patch (571 Bytes) 0011212_v3.patch Administrator Admin, 2009-08-25 19:08
Actions #1

Updated by Christian Kuhn over 15 years ago

Please try attached patch.

TS:
config.admPanel = 1

User-TS:
admPanel >

Actions #2

Updated by Niels Fröhling over 15 years ago

I'll try. Maybe I don't find the time until bug-day.

Actions #3

Updated by Niels Fröhling over 15 years ago

I think your patch can work from reading, but I actually added a check for the validity of the adminPanel-object itself:

if ($this->adminPanel ...

I don't know which makes more sense. Your solution, in the presence of wrong-doing, clearly will produce a noticable error, which probably is desired.

Actions #4

Updated by Rupert Germann over 15 years ago

I attached a new patch (v2).
I moved the check for $BE_USER->extAdmEnabled to index_ts (like it was in 4.2.x) because then the calls to echo and to displayAdminPanel() are prevented is no admPanel is enabled.

Actions #5

Updated by Oliver Hader about 15 years ago

Rupert, I don't think the echo with no content is bad. However, an alternative would be a new method t3lib_tsfebeuserauth->isAdminPanelEnabled() - I'd like to have the logic whether the admin panel shall be displayed or not at one place.

Actions #6

Updated by Steffen Kamper about 15 years ago

committed to trunk rev 5825

Actions

Also available in: Atom PDF