check if file is_readable
thanks @akirk
This commit is contained in:
parent
26a1dc9be5
commit
baa8027e3f
1 changed files with 1 additions and 1 deletions
|
@ -74,7 +74,7 @@ spl_autoload_register(
|
||||||
$filename = 'class-' . strtr( $class, '_', '-' );
|
$filename = 'class-' . strtr( $class, '_', '-' );
|
||||||
$file = $base_dir . $filename . '.php';
|
$file = $base_dir . $filename . '.php';
|
||||||
|
|
||||||
if ( file_exists( $file ) ) {
|
if ( file_exists( $file ) && is_readable( $file ) ) {
|
||||||
require_once $file;
|
require_once $file;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue