[TYPO3-core] RFC: #14258: t3lib_extMgm should provide API to determinde whether ext is installed or not

Jeff Segars jsegars at alumni.rice.edu
Tue May 25 01:39:35 CEST 2010


On 4/30/10 5:33 AM, Tolleiv.Nietsch wrote:
> This is an SVN patch request.
>
> Type: Bugfix
>
> Bugtracker references:
> http://bugs.typo3.org/view.php?id=14258
>
> Branches:
> trunk 4-3
>
> Problem:
> For a long time "t3lib_extMgm::isLoaded()" was used to determine whether
> an extension is installed or not, but due to the "doNotLoadInFE" feature
> the result of "isLoaded" might not be enough to determine whether the
> extension really exists or not.
>
> Solution:
> The attached patch adds a isInstalled method which can be used context
> independent to determine the existence of an extension:
>
> Additional information:
> Why is that relevant: - check EXT:tt_news/trunk/pi/class.tx_ttnews.php -
> where "t3lib_extMgm::isLoaded('version')" is used to determine whether
> "versioning" is enabled or not. This worked fine for years but doesn't
> anymore due to the fact that "version" is not loaded in the frontend.
>
> Due to the fact that especially "t3lib_extMgm::isInstalled('version')"
> is / will be needed very often, I ask to get this into 4.3 and 4.4 to
> enable proper ext handling.
>
> Cheers,
> Tolleiv
>

One comment on the patch...

> $isInstalled = t3lib_div::inList($GLOBALS['TYPO3_CONF_VARS']['EXT']['extList'], $key);
> if ($exitOnError && !isset($isInstalled)) {

Shouldn't it just be !$isInstalled since $isInstalled is always set?

Once that is corrected, you have my +1 on reading and testing if Olly 
and Benni are fine with putting it in 4.3 and 4.4.

Thanks,
Jeff



More information about the TYPO3-team-core mailing list