refactoring various classes.

This commit is contained in:
Taylor Otwell
2011-11-21 19:09:48 -06:00
parent b0ffc0183a
commit 994949c6ce
6 changed files with 53 additions and 28 deletions

View File

@@ -53,8 +53,8 @@ class Autoloader {
protected static function find($class)
{
// After PHP namespaces were introduced, most libaries ditched underscores for
// namespaces to indicate the class directory hierarchy. We will check for the
// presence of namespace slashes to determine the directory separator.
// for namespaces to indicate the class directory hierarchy. We will check for
// the presence of namespace slashes to determine the directory separator.
$separator = (strpos($class, '\\') !== false) ? '\\' : '_';
$library = substr($class, 0, strpos($class, $separator));