support more more depth in the namespaces
This commit is contained in:
parent
b85b0167c0
commit
cfa8974ffa
1 changed files with 3 additions and 1 deletions
|
@ -65,7 +65,9 @@ spl_autoload_register(
|
||||||
$class = str_replace( 'activitypub\\', '', $class );
|
$class = str_replace( 'activitypub\\', '', $class );
|
||||||
|
|
||||||
if ( false !== strpos( $class, '\\' ) ) {
|
if ( false !== strpos( $class, '\\' ) ) {
|
||||||
list( $sub_dir, $class ) = explode( '\\', $class );
|
$parts = explode( '\\', $class );
|
||||||
|
$class = array_pop( $parts );
|
||||||
|
$sub_dir = implode( '/', $parts );
|
||||||
$base_dir = $base_dir . $sub_dir . '/';
|
$base_dir = $base_dir . $sub_dir . '/';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue