Merge pull request #825 from owncloud/oc_namespace
Autoload classes with 'OC' namespace prefix.
This commit is contained in:
commit
2361639a0d
|
@ -90,6 +90,9 @@ class OC{
|
|||
elseif(strpos($className, 'OC_')===0) {
|
||||
$path = strtolower(str_replace('_', '/', substr($className, 3)) . '.php');
|
||||
}
|
||||
elseif(strpos($className, 'OC\\')===0) {
|
||||
$path = strtolower(str_replace('\\', '/', substr($className, 3)) . '.php');
|
||||
}
|
||||
elseif(strpos($className, 'OCP\\')===0) {
|
||||
$path = 'public/'.strtolower(str_replace('\\', '/', substr($className, 3)) . '.php');
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue