mirror of
https://github.com/predis/predis.git
synced 2026-08-30 04:02:22 +00:00
Use the new Predis\Autoloader class for tests and examples.
This commit is contained in:
@@ -1,12 +1,8 @@
|
||||
<?php
|
||||
|
||||
spl_autoload_register(function($class) {
|
||||
$file = __DIR__.'/../lib/'.strtr($class, '\\', '/').'.php';
|
||||
if (file_exists($file)) {
|
||||
require $file;
|
||||
return true;
|
||||
}
|
||||
});
|
||||
require __DIR__.'/../lib/Predis/Autoloader.php';
|
||||
|
||||
Predis\Autoloader::register();
|
||||
|
||||
$single_server = array(
|
||||
'host' => '127.0.0.1',
|
||||
|
||||
+3
-8
@@ -1,12 +1,7 @@
|
||||
<?php
|
||||
|
||||
spl_autoload_register(function($class)
|
||||
{
|
||||
$file = __DIR__.'/../lib/'.strtr($class, '\\', '/').'.php';
|
||||
if (file_exists($file)) {
|
||||
require $file;
|
||||
return true;
|
||||
}
|
||||
});
|
||||
require __DIR__.'/../lib/Predis/Autoloader.php';
|
||||
|
||||
Predis\Autoloader::register();
|
||||
|
||||
require __DIR__.'/PredisShared.php';
|
||||
|
||||
Reference in New Issue
Block a user