mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-07 10:22:56 +00:00
Merge branch 'stable'
This commit is contained in:
@ -32,6 +32,8 @@ use function file_exists;
|
||||
use function gettype;
|
||||
use function is_array;
|
||||
use function is_dir;
|
||||
use function is_float;
|
||||
use function is_int;
|
||||
use function is_string;
|
||||
use function mkdir;
|
||||
use function strtolower;
|
||||
@ -81,10 +83,11 @@ class ResourcePackManager{
|
||||
}
|
||||
|
||||
foreach($resourceStack as $pos => $pack){
|
||||
if(!is_string($pack)){
|
||||
if(!is_string($pack) && !is_int($pack) && !is_float($pack)){
|
||||
$logger->critical("Found invalid entry in resource pack list at offset $pos of type " . gettype($pack));
|
||||
continue;
|
||||
}
|
||||
$pack = (string) $pack;
|
||||
try{
|
||||
$packPath = Path::join($this->path, $pack);
|
||||
if(!file_exists($packPath)){
|
||||
|
Reference in New Issue
Block a user