diff options
author | Pierre Schmitz <pierre@archlinux.de> | 2006-10-11 20:21:25 +0000 |
---|---|---|
committer | Pierre Schmitz <pierre@archlinux.de> | 2006-10-11 20:21:25 +0000 |
commit | d81f562b712f2387fa02290bf2ca86392ab356f2 (patch) | |
tree | d666cdefbe6ac320827a2c6cb473581b46e22c4c /includes/ObjectCache.php | |
parent | 183851b06bd6c52f3cae5375f433da720d410447 (diff) |
Aktualisierung auf Version 1.8.1
Diffstat (limited to 'includes/ObjectCache.php')
-rw-r--r-- | includes/ObjectCache.php | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/includes/ObjectCache.php b/includes/ObjectCache.php index fe7417d2..2b26cf4e 100644 --- a/includes/ObjectCache.php +++ b/includes/ObjectCache.php @@ -69,13 +69,10 @@ function &wfGetCache( $inputType ) { } elseif ( $type == CACHE_ACCEL ) { if ( !array_key_exists( CACHE_ACCEL, $wgCaches ) ) { if ( function_exists( 'eaccelerator_get' ) ) { - require_once( 'BagOStuff.php' ); $wgCaches[CACHE_ACCEL] = new eAccelBagOStuff; } elseif ( function_exists( 'apc_fetch') ) { - require_once( 'BagOStuff.php' ); $wgCaches[CACHE_ACCEL] = new APCBagOStuff; } elseif ( function_exists( 'mmcache_get' ) ) { - require_once( 'BagOStuff.php' ); $wgCaches[CACHE_ACCEL] = new TurckBagOStuff; } else { $wgCaches[CACHE_ACCEL] = false; @@ -84,11 +81,15 @@ function &wfGetCache( $inputType ) { if ( $wgCaches[CACHE_ACCEL] !== false ) { $cache =& $wgCaches[CACHE_ACCEL]; } + } elseif ( $type == CACHE_DBA ) { + if ( !array_key_exists( CACHE_DBA, $wgCaches ) ) { + $wgCaches[CACHE_DBA] = new DBABagOStuff; + } + $cache =& $wgCaches[CACHE_DBA]; } - + if ( $type == CACHE_DB || ( $inputType == CACHE_ANYTHING && $cache === false ) ) { if ( !array_key_exists( CACHE_DB, $wgCaches ) ) { - require_once( 'BagOStuff.php' ); $wgCaches[CACHE_DB] = new MediaWikiBagOStuff('objectcache'); } $cache =& $wgCaches[CACHE_DB]; |