|
10 | 10 | spl_autoload_register(function ($class) {
|
11 | 11 | $file = null;
|
12 | 12 |
|
13 |
| - if (0 === strpos($class,'MyLib\StrUtil\Example\\')) { |
14 |
| - $path = str_replace('\\', '/', substr($class, strlen('MyLib\StrUtil\Example\\'))); |
| 13 | + if (0 === strpos($class,'MyLib\SysUtil\Example\\')) { |
| 14 | + $path = str_replace('\\', '/', substr($class, strlen('MyLib\SysUtil\Example\\'))); |
15 | 15 | $file = dirname(__DIR__) . "/example/{$path}.php";
|
16 |
| - } elseif (0 === strpos($class,'MyLib\StrUtil\Test\\')) { |
17 |
| - $path = str_replace('\\', '/', substr($class, strlen('MyLib\StrUtil\Test\\'))); |
| 16 | + } elseif (0 === strpos($class,'MyLib\SysUtil\Test\\')) { |
| 17 | + $path = str_replace('\\', '/', substr($class, strlen('MyLib\SysUtil\Test\\'))); |
18 | 18 | $file = __DIR__ . "/{$path}.php";
|
19 |
| - } elseif (0 === strpos($class,'MyLib\StrUtil\\')) { |
20 |
| - $path = str_replace('\\', '/', substr($class, strlen('MyLib\StrUtil\\'))); |
| 19 | + } elseif (0 === strpos($class,'MyLib\SysUtil\\')) { |
| 20 | + $path = str_replace('\\', '/', substr($class, strlen('MyLib\SysUtil\\'))); |
21 | 21 | $file = dirname(__DIR__) . "/src/{$path}.php";
|
22 | 22 | }
|
23 | 23 |
|
|
0 commit comments