summaryrefslogtreecommitdiffstats
path: root/lib/base.php
diff options
context:
space:
mode:
authorBrice Maron <brice@bmaron.net>2012-06-21 22:22:36 +0000
committerBrice Maron <brice@bmaron.net>2012-06-21 22:22:36 +0000
commitb5953e7a83d2dc8f1483c7809414dca7a1cde990 (patch)
tree385a3d73419824ca2f3a7b24f60e365dc3eb0cb1 /lib/base.php
parentfcaf04cad96aa8fe2937ec9def60e77c7f4bb795 (diff)
downloadnextcloud-server-b5953e7a83d2dc8f1483c7809414dca7a1cde990.tar.gz
nextcloud-server-b5953e7a83d2dc8f1483c7809414dca7a1cde990.zip
Provide solution for smoother migration for apps to multi-app dir
Diffstat (limited to 'lib/base.php')
-rw-r--r--lib/base.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/base.php b/lib/base.php
index 2f16f7dab4c..22dd86535a0 100644
--- a/lib/base.php
+++ b/lib/base.php
@@ -71,7 +71,11 @@ class OC{
*/
public static function autoload($className){
if(array_key_exists($className,OC::$CLASSPATH)){
- require_once OC::$CLASSPATH[$className];
+ /** @TODO: Remove this when necessary
+ Remove "apps/" from inclusion path for smooth migration to mutli app dir
+ */
+ $path = preg_replace('/apps\//','', OC::$CLASSPATH[$className]);
+ require_once $path;
}
elseif(strpos($className,'OC_')===0){
require_once strtolower(str_replace('_','/',substr($className,3)) . '.php');