From 5a5a5b203290e67035aea93eb832c703278380d3 Mon Sep 17 00:00:00 2001 From: Roeland Jago Douma Date: Fri, 13 May 2016 11:10:21 +0200 Subject: OC_xx all live in the legacy folder --- lib/autoloader.php | 1 - 1 file changed, 1 deletion(-) (limited to 'lib') diff --git a/lib/autoloader.php b/lib/autoloader.php index 6a427848235..ad76dd362bb 100644 --- a/lib/autoloader.php +++ b/lib/autoloader.php @@ -102,7 +102,6 @@ class Autoloader { } } elseif (strpos($class, 'OC_') === 0) { $paths[] = \OC::$SERVERROOT . '/lib/private/legacy/' . strtolower(str_replace('_', '/', substr($class, 3)) . '.php'); - $paths[] = \OC::$SERVERROOT . '/lib/private/' . strtolower(str_replace('_', '/', substr($class, 3)) . '.php'); } elseif (strpos($class, 'OC\\') === 0) { $split = explode('\\', $class, 3); -- cgit v1.2.3 From a037c10c88b417ca009a8c863d392213be21f999 Mon Sep 17 00:00:00 2001 From: Roeland Jago Douma Date: Fri, 13 May 2016 11:11:01 +0200 Subject: All \OC\ classes are handled by the composer autoloader --- lib/autoloader.php | 17 ----------------- 1 file changed, 17 deletions(-) (limited to 'lib') diff --git a/lib/autoloader.php b/lib/autoloader.php index ad76dd362bb..9cc573c0997 100644 --- a/lib/autoloader.php +++ b/lib/autoloader.php @@ -102,23 +102,6 @@ class Autoloader { } } elseif (strpos($class, 'OC_') === 0) { $paths[] = \OC::$SERVERROOT . '/lib/private/legacy/' . strtolower(str_replace('_', '/', substr($class, 3)) . '.php'); - } elseif (strpos($class, 'OC\\') === 0) { - $split = explode('\\', $class, 3); - - if (count($split) === 3) { - $split[1] = strtolower($split[1]); - - if ($split[1] === 'core') { - // Covered by PSR-4 autoloader - } else if ($split[1] === 'settings') { - // Covered by PSR-4 autoloader - } else { - $paths[] = \OC::$SERVERROOT . '/lib/private/' . $split[1] . '/' . strtolower(str_replace('\\', '/', $split[2])) . '.php'; - } - - } else { - $paths[] = \OC::$SERVERROOT . '/lib/private/' . strtolower(str_replace('\\', '/', $split[1])) . '.php'; - } } elseif (strpos($class, 'OCP\\') === 0) { $paths[] = \OC::$SERVERROOT . '/lib/public/' . strtolower(str_replace('\\', '/', substr($class, 4)) . '.php'); } elseif (strpos($class, 'OCA\\') === 0) { -- cgit v1.2.3