Merge branch 'stable'

This commit is contained in:
Dylan K. Taylor
2021-11-01 18:13:24 +00:00
13 changed files with 1640 additions and 1511 deletions

View File

@ -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)){