// Remove unused $tables property from ObjectModel + improve Cache

This commit is contained in:
rMalie committed 2011-12-09 10:24:48 +00:00
1 parent 091025371e
commit 2daf87f506
16 files changed
+24 -43

No files matched your search

+11 -1
View File
@@ -314,6 +314,16 @@ abstract class CacheCore
public static function clean($key)
{
unset(Cache::$local[$key]);
if (strpos($key, '*'))
{
$regexp = str_replace('\\*', '.*', preg_quote($key, '#'));
foreach (array_keys(Cache::$local) as $key)
if (preg_match('#^'.$regexp.'$#', $key))
unset(Cache::$local[$key]);
}
else
unset(Cache::$local[$key]);
d(array_keys(Cache::$local));
}
}