mirror of
https://github.com/Combodo/iTop.git
synced 2026-02-12 23:14:18 +01:00
Fixed the "Reset(APC)Cache" at the end of the installation.
SVN:trunk[2310]
This commit is contained in:
@@ -5076,18 +5076,18 @@ abstract class MetaModel
|
||||
return $aEntries;
|
||||
}
|
||||
|
||||
public static function ResetCache($sEnvironment = null)
|
||||
public static function ResetCache($sEnvironmentId = null)
|
||||
{
|
||||
if (!function_exists('apc_delete')) return;
|
||||
if (is_null($sEnvironment))
|
||||
if (is_null($sEnvironmentId))
|
||||
{
|
||||
$sEnvironment = MetaModel::GetEnvironmentId();
|
||||
$sEnvironmentId = MetaModel::GetEnvironmentId();
|
||||
}
|
||||
|
||||
$sAppIdentity = 'itop-'.$sEnvironment;
|
||||
$sAppIdentity = 'itop-'.$sEnvironmentId;
|
||||
Dict::ResetCache($sAppIdentity);
|
||||
|
||||
foreach(self::GetCacheEntries($sEnvironment) as $sKey => $aAPCInfo)
|
||||
foreach(self::GetCacheEntries($sEnvironmentId) as $sKey => $aAPCInfo)
|
||||
{
|
||||
$sAPCKey = $aAPCInfo['info'];
|
||||
apc_delete($sAPCKey);
|
||||
|
||||
@@ -783,6 +783,6 @@ class ApplicationInstaller
|
||||
|
||||
// Ready to go !!
|
||||
require_once(APPROOT.'core/dict.class.inc.php');
|
||||
MetaModel::ResetCache($sTargetEnvironment);
|
||||
MetaModel::ResetCache();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user