mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-07-04 17:20:02 +00:00
Merge branch 'stable'
# Conflicts: # resources/vanilla # src/network/mcpe/convert/LegacySkinAdapter.php # tests/phpstan/configs/check-explicit-mixed-baseline.neon # tests/phpstan/configs/phpstan-bugs.neon
This commit is contained in:
commit
64e9647334
@ -25,9 +25,9 @@ namespace pocketmine\network\mcpe\convert;
|
||||
|
||||
use pocketmine\entity\InvalidSkinException;
|
||||
use pocketmine\entity\Skin;
|
||||
|
||||
use pocketmine\network\mcpe\protocol\types\SkinData;
|
||||
use pocketmine\network\mcpe\protocol\types\SkinImage;
|
||||
use function is_array;
|
||||
use function is_string;
|
||||
use function json_decode;
|
||||
use function json_encode;
|
||||
@ -60,7 +60,7 @@ class LegacySkinAdapter implements SkinAdapter{
|
||||
$capeData = $data->isPersonaCapeOnClassic() ? "" : $data->getCapeImage()->getData();
|
||||
|
||||
$resourcePatch = json_decode($data->getResourcePatch(), true);
|
||||
if(isset($resourcePatch["geometry"]["default"]) && is_string($resourcePatch["geometry"]["default"])){
|
||||
if(is_array($resourcePatch) && isset($resourcePatch["geometry"]["default"]) && is_string($resourcePatch["geometry"]["default"])){
|
||||
$geometryName = $resourcePatch["geometry"]["default"];
|
||||
}else{
|
||||
throw new InvalidSkinException("Missing geometry name field");
|
||||
|
@ -145,11 +145,6 @@ parameters:
|
||||
count: 1
|
||||
path: ../../../src/network/mcpe/compression/CompressBatchTask.php
|
||||
|
||||
-
|
||||
message: "#^Cannot access offset 'geometry' on mixed\\.$#"
|
||||
count: 3
|
||||
path: ../../../src/network/mcpe/convert/LegacySkinAdapter.php
|
||||
|
||||
-
|
||||
message: "#^Method pocketmine\\\\network\\\\mcpe\\\\raklib\\\\PthreadsChannelReader\\:\\:read\\(\\) should return string\\|null but returns mixed\\.$#"
|
||||
count: 1
|
||||
|
@ -55,11 +55,6 @@ parameters:
|
||||
count: 1
|
||||
path: ../../../src/network/mcpe/compression/ZlibCompressor.php
|
||||
|
||||
-
|
||||
message: "#^Strict comparison using \\=\\=\\= between array and false will always evaluate to false\\.$#"
|
||||
count: 1
|
||||
path: ../../../src/utils/Timezone.php
|
||||
|
||||
-
|
||||
message: "#^Strict comparison using \\=\\=\\= between string and false will always evaluate to false\\.$#"
|
||||
count: 1
|
||||
|
Loading…
x
Reference in New Issue
Block a user