diff --git a/lib/Cake/Configure/PhpReader.php b/lib/Cake/Configure/PhpReader.php index f81cd067a..b6682d910 100644 --- a/lib/Cake/Configure/PhpReader.php +++ b/lib/Cake/Configure/PhpReader.php @@ -72,10 +72,10 @@ class PhpReader implements ConfigReaderInterface { } else { $file = $this->_path . $key; } - if (!file_exists($file)) { - $file .= '.php'; - if (!file_exists($file)) { - throw new ConfigureException(__d('cake_dev', 'Could not load configuration files: %s or %s', substr($file, 0, -4), $file)); + $file .= '.php'; + if (!is_file($file)) { + if (!is_file(substr($file, 0, -4))) { + throw new ConfigureException(__d('cake_dev', 'Could not load configuration files: %s or %s', $file, substr($file, 0, -4))); } } include $file;