summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lib/autoloader.php2
-rw-r--r--lib/base.php6
-rw-r--r--lib/public/Template.php (renamed from lib/public/template.php)0
-rw-r--r--tests/lib/AutoLoaderTest.php16
4 files changed, 2 insertions, 22 deletions
diff --git a/lib/autoloader.php b/lib/autoloader.php
index 73783603438..89b66a426a7 100644
--- a/lib/autoloader.php
+++ b/lib/autoloader.php
@@ -102,8 +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, 'OCP\\') === 0) {
- $paths[] = \OC::$SERVERROOT . '/lib/public/' . strtolower(str_replace('\\', '/', substr($class, 4)) . '.php');
} elseif (strpos($class, 'OCA\\') === 0) {
list(, $app, $rest) = explode('\\', $class, 3);
$app = strtolower($app);
diff --git a/lib/base.php b/lib/base.php
index eddcec97b1f..391bcf865a0 100644
--- a/lib/base.php
+++ b/lib/base.php
@@ -481,11 +481,7 @@ class OC {
$loaderStart = microtime(true);
require_once __DIR__ . '/autoloader.php';
self::$loader = new \OC\Autoloader([
- OC::$SERVERROOT . '/lib',
- OC::$SERVERROOT . '/core',
- OC::$SERVERROOT . '/settings',
- OC::$SERVERROOT . '/ocs',
- OC::$SERVERROOT . '/ocs-provider',
+ OC::$SERVERROOT . '/lib/private/legacy',
]);
if (defined('PHPUNIT_RUN')) {
self::$loader->addValidRoot(OC::$SERVERROOT . '/tests');
diff --git a/lib/public/template.php b/lib/public/Template.php
index 7e46745c9d8..7e46745c9d8 100644
--- a/lib/public/template.php
+++ b/lib/public/Template.php
diff --git a/tests/lib/AutoLoaderTest.php b/tests/lib/AutoLoaderTest.php
index a97ba3f768e..38ba29bc085 100644
--- a/tests/lib/AutoLoaderTest.php
+++ b/tests/lib/AutoLoaderTest.php
@@ -19,18 +19,6 @@ class AutoLoaderTest extends TestCase {
$this->loader = new \OC\AutoLoader([]);
}
- public function testLeadingSlashOnClassName() {
- $this->assertEquals([
- \OC::$SERVERROOT . '/lib/public/files/storage/local.php',
- ], $this->loader->findClass('\OCP\Files\Storage\Local'));
- }
-
- public function testNoLeadingSlashOnClassName() {
- $this->assertEquals([
- \OC::$SERVERROOT . '/lib/public/files/storage/local.php',
- ], $this->loader->findClass('OCP\Files\Storage\Local'));
- }
-
public function testLegacyPath() {
$this->assertEquals([
\OC::$SERVERROOT . '/lib/private/legacy/files.php',
@@ -50,9 +38,7 @@ class AutoLoaderTest extends TestCase {
}
public function testLoadPublicNamespace() {
- $this->assertEquals([
- \OC::$SERVERROOT . '/lib/public/foo/bar.php',
- ], $this->loader->findClass('OCP\Foo\Bar'));
+ $this->assertEquals([], $this->loader->findClass('OCP\Foo\Bar'));
}
public function testLoadAppNamespace() {