Follow-up to #11358: Minor cleanup
authorMichael Stucki <michael.stucki@typo3.org>
Tue, 23 Jun 2009 12:18:12 +0000 (12:18 +0000)
committerMichael Stucki <michael.stucki@typo3.org>
Tue, 23 Jun 2009 12:18:12 +0000 (12:18 +0000)
git-svn-id: https://svn.typo3.org/TYPO3v4/Core/trunk@5620 709f56b5-9817-0410-a4d7-c38de5d9e867

ChangeLog
t3lib/class.t3lib_page.php

index 9ac91bb..d51d6d1 100755 (executable)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,6 @@
 2009-06-23  Michael Stucki  <michael@typo3.org>
 
+       * Follow-up to #11358: Minor cleanup
        * Fixed bug #10791: Performance improvement: Skip cHash check if page is already non-cached
        * Fixed bug #11368: Ignore ENABLE_INSTALL_TOOL file if it is older than one hour
 
index 2f488a6..51e78f7 100644 (file)
@@ -219,19 +219,21 @@ class t3lib_pageSelect {
                if ($this->cache_getPage_noCheck[$uid]) {
                        return $this->cache_getPage_noCheck[$uid];
                }
+
                $res = $GLOBALS['TYPO3_DB']->exec_SELECTquery('*', 'pages', 'uid='.intval($uid).$this->deleteClause('pages'));
                $row = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($res);
                $GLOBALS['TYPO3_DB']->sql_free_result($res);
-               if ($row)       {
+
+               $result = array();
+               if ($row) {
                        $this->versionOL('pages',$row);
-                       if (is_array($row))     {
-                               $row = $this->getPageOverlay($row);
-                               $this->cache_getPage_noCheck[$uid] = $row;
-                               return $row;
+                       if (is_array($row)) {
+                               $result = $this->getPageOverlay($row);
                        }
                }
-               $this->cache_getPage_noCheck[$uid] = array();
-               return array();
+               $this->cache_getPage_noCheck[$uid] = $result;
+
+               return $result;
        }
 
        /**