[TASK] Remove array duplication in T3_SERVICES
authorChristian Kuhn <lolli@schwarzbu.ch>
Mon, 22 Aug 2011 14:43:13 +0000 (16:43 +0200)
committerSusanne Moog <typo3@susannemoog.de>
Mon, 22 Aug 2011 16:51:30 +0000 (18:51 +0200)
These informations are important for a service:

* Extension name of a service implementation (e.g. 'saltedpasswords')
* Service type (eg. 'auth')
* Class implementing the service
  (service key, e.g. 'tx_saltedpasswords_sv1').

t3lib_extMgm::addService() registers a service in global array
$T3_SERVICES[type][key].
Additionally it registers the same service as $T3_SERVICES[key][key].

The latter registration is actually never used by any other service
method in the core and can be removed to simplify this handling.

Change-Id: I2c8c53bb763b0a41e5c2488bbcef96f7e1505c9f
Resolves: #29164
Reviewed-on: http://review.typo3.org/4522
Reviewed-by: Steffen Gebert
Tested-by: Steffen Gebert
Reviewed-by: Susanne Moog
Tested-by: Susanne Moog
t3lib/class.t3lib_extmgm.php

index a9310b8..ea752a9 100644 (file)
@@ -1015,13 +1015,6 @@ final class t3lib_extMgm {
                        $GLOBALS['T3_SERVICES'][$serviceType][$serviceKey]['serviceKey'] = $serviceKey;
                        $GLOBALS['T3_SERVICES'][$serviceType][$serviceKey]['serviceType'] = $serviceType;
 
-
-                               // mapping a service key to a service type
-                               // all service keys begin with tx_ or Tx_ - service types don't
-                               // this way a selection of a special service key as service type is easy
-                       $GLOBALS['T3_SERVICES'][$serviceKey][$serviceKey] = &$GLOBALS['T3_SERVICES'][$serviceType][$serviceKey];
-
-
                                // change the priority (and other values) from $GLOBALS['TYPO3_CONF_VARS']
                                // $GLOBALS['TYPO3_CONF_VARS']['T3_SERVICES'][$serviceType][$serviceKey]['priority']
                                // even the activation is possible (a unix service might be possible on windows for some reasons)