[BUGFIX] EM update module doesn't accept cache_extension table
authorSteffen Kamper <info@sk-typo3.de>
Wed, 9 Mar 2011 17:30:10 +0000 (18:30 +0100)
committerSteffen Kamper <info@sk-typo3.de>
Tue, 22 Mar 2011 10:59:43 +0000 (11:59 +0100)
You see only the message:
To get and update the list, go to the section "Import extensions" and use the button "Retrieve/Update".
even if table is filled.
 The reason is that it looks for typo3temp/extensions.xml.hz instead checking if the table has records.

 Solution:
 Check table count instead.

 Resolves: #M17907

Change-Id: I6c2905a0afce08f70c4743d66a1b521de30044fb
Reviewed-on: http://review.typo3.org/1108
Reviewed-by: Peter Beernink <p.beernink@drecomm.nl>
Tested-by: Peter Beernink <p.beernink@drecomm.nl>
Reviewed-by: Tolleiv Nietsch <info@tolleiv.de>
Reviewed-by: Steffen Kamper <info@sk-typo3.de>
Tested-by: Steffen Kamper <info@sk-typo3.de>
typo3/sysext/em/classes/index.php

index 1c75d20..e0948df 100644 (file)
@@ -2440,7 +2440,8 @@ class SC_mod_tools_em_index extends t3lib_SCbase {
                global $LANG;
                $content = '';
 
-               if (is_file(PATH_site . 'typo3temp/extensions.xml.gz')) {
+               $count = intval(tx_em_Database::getExtensionCountFromRepository());
+               if ($count > 0) {
                        $content = $this->extensionList->showExtensionsToUpdate()
                                        . t3lib_BEfunc::getFuncCheck(0, 'SET[display_installed]', $this->MOD_SETTINGS['display_installed'], '', '', 'id="checkDisplayInstalled"')
                                        . '&nbsp;<label for="checkDisplayInstalled">' . $LANG->sL('LLL:EXT:lang/locallang_mod_tools_em.xml:display_nle') . '</label><br />'