Changed t3lib_page::deleteClause to make it JOIN-safe
authorMartin Kutschker <martin.t.kutschker@blackbox.net>
Tue, 19 Apr 2005 08:54:38 +0000 (08:54 +0000)
committerMartin Kutschker <martin.t.kutschker@blackbox.net>
Tue, 19 Apr 2005 08:54:38 +0000 (08:54 +0000)
git-svn-id: https://svn.typo3.org/TYPO3v4/Core/trunk@661 709f56b5-9817-0410-a4d7-c38de5d9e867

t3lib/class.t3lib_page.php

index dc8742a..ce86e71 100755 (executable)
@@ -867,9 +867,9 @@ class t3lib_pageSelect {
        function deleteClause($table)   {
                global $TCA;
                if (!strcmp($table,'pages'))    {       // Hardcode for pages...:
-                       return ' AND deleted=0';
+                       return ' AND pages.deleted=0';
                } else {
-                       return $TCA[$table]['ctrl']['delete'] ? ' AND '.$TCA[$table]['ctrl']['delete'].'=0' : '';
+                       return $TCA[$table]['ctrl']['delete'] ? ' AND '.$table.'.'.$TCA[$table]['ctrl']['delete'].'=0' : '';
                }
        }