Only cache if there user has access to the image dir

This commit is contained in:
Nathan Gray 2015-03-09 19:50:09 +00:00
parent cbae778539
commit a9af75f416

View File

@ -924,15 +924,9 @@ class common
$app_map[$name] = egw_vfs::download_url($img); $app_map[$name] = egw_vfs::download_url($img);
} }
} }
} egw_cache::setInstance(__CLASS__, $cache_name, $map, 86400); // cache for one day
else if ($dir)
{
// No access to the VFS, don't cache for everyone or custom icons
// will be missing. Just cache for current session.
$cache_level = egw_cache::SESSION;
} }
//error_log(__METHOD__."('$template_set') took ".(microtime(true)-$starttime).' secs'); //error_log(__METHOD__."('$template_set') took ".(microtime(true)-$starttime).' secs');
egw_cache::setCache($cache_level,__CLASS__, $cache_name, $map, 86400); // cache for one day
//echo "<p>template_set=".array2string($template_set)."</p>\n"; _debug_array($map); //echo "<p>template_set=".array2string($template_set)."</p>\n"; _debug_array($map);
return $map; return $map;
} }