Skip to content

Commit

Permalink
reverted previous changes to Fuel::find_file(), and only add the mult…
Browse files Browse the repository at this point in the history
…iple/single cache identifier at the end
  • Loading branch information
WanWizard committed May 10, 2011
1 parent 0f43453 commit e14bc5a
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions classes/fuel.php
Original file line number Diff line number Diff line change
Expand Up @@ -229,7 +229,7 @@ public static function finish()
*/
public static function find_file($directory, $file, $ext = '.php', $multiple = false, $cache = true)
{
$cache_id = $multiple ? 'M.' : 'S.';
$cache_id = '';
$paths = array();

$found = $multiple ? array() : false;
Expand Down Expand Up @@ -258,7 +258,7 @@ public static function find_file($directory, $file, $ext = '.php', $multiple = f
}

// if not found, use the cascading filesystem to find the file
if (empty($paths))
if (empty($cache_id))
{
$paths = static::$_paths;

Expand All @@ -272,7 +272,7 @@ public static function find_file($directory, $file, $ext = '.php', $multiple = f

$path = $directory.DS.strtolower($file).$ext;

$cache_id = md5($cache_id);
$cache_id = md5(($multiple ? 'M.' : 'S.').$cache_id);

if (static::$path_cache !== null and array_key_exists($cache_id.$path, static::$path_cache))
{
Expand Down

0 comments on commit e14bc5a

Please sign in to comment.