[TYPO3-core] RFC #16832: Bug: error when using t3lib_TCEmain->clear_cacheCmd in frontend
Krystian Szymukowicz
t33k at prolabium.com
Sat Dec 25 19:02:14 CET 2010
Hi,
This is an SVN patch request.
Type: Bugfix
BT reference: http://bugs.typo3.org/view.php?id=16832
Branches: trunk
PROBLEM:
in rev. 8481 there has been added writelog when clearing the cache.
public function clear_cacheCmd($cacheCmd) {
$this->BE_USER->writelog(..........
But some extesions like Dmitry Dulepov 'comments' are using
'clear_cacheCmd' from frontend where $this->BE_USER is not initialised.
So we get:
Fatal error: Call to a member function writelog() on a non-object in
T:\workspace-typo3\typo3\typo3_src-svn-trunk\t3lib\class.t3lib_tcemain.php
on line 6761
SOLUTION:
Check if we are in BE mode while writing the log.
if (TYPO3_MODE === 'BE') {
$this->BE_USER->writelog(....
}
--
grtz
Krystian Szymukowicz
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 16832.patch
URL: <http://lists.typo3.org/pipermail/typo3-team-core/attachments/20101225/828bf485/attachment.asc>
More information about the TYPO3-team-core
mailing list