summaryrefslogtreecommitdiffstats
path: root/3rdparty/Sabre/autoload.php
diff options
context:
space:
mode:
Diffstat (limited to '3rdparty/Sabre/autoload.php')
-rw-r--r--[-rwxr-xr-x]3rdparty/Sabre/autoload.php28
1 files changed, 12 insertions, 16 deletions
diff --git a/3rdparty/Sabre/autoload.php b/3rdparty/Sabre/autoload.php
index c7b537d83d3..505bd36efb0 100755..100644
--- a/3rdparty/Sabre/autoload.php
+++ b/3rdparty/Sabre/autoload.php
@@ -1,31 +1,27 @@
<?php
/**
- * SabreDAV's PHP autoloader
+ * SabreDAV's autoloader
*
- * If you love the autoloader, and don't care as much about performance, this
- * file register a new autoload function using spl_autoload_register.
+ * This file is kept for backwards compatibility purposes.
+ * SabreDAV now uses the composer autoloader.
+ *
+ * You should stop including this file, and include 'vendor/autoload.php'
+ * instead.
*
* @package Sabre
* @subpackage DAV
+ * @deprecated Will be removed in a future version!
* @copyright Copyright (C) 2007-2012 Rooftop Solutions. All rights reserved.
* @author Evert Pot (http://www.rooftopsolutions.nl/)
* @license http://code.google.com/p/sabredav/wiki/License Modified BSD License
*/
/**
- * @param string $className
- * @return void
+ * We are assuming that the composer autoloader is just 2 directories up.
+ *
+ * This is not the case when sabredav is installed as a dependency. But, in
+ * those cases it's not expected that people will look for this file anyway.
*/
-function Sabre_autoload($className) {
-
- if(strpos($className,'Sabre_')===0) {
-
- include dirname(__FILE__) . '/' . str_replace('_','/',substr($className,6)) . '.php';
-
- }
-
-}
-
-spl_autoload_register('Sabre_autoload');
+require __DIR__ . '/../../vendor/autoload.php';