fix phpstan

This commit is contained in:
Dylan K. Taylor 2022-05-13 21:03:49 +01:00
parent 4430f6c5fd
commit 2f2ffe0aa4
No known key found for this signature in database
GPG Key ID: 8927471A91CAFD3D
3 changed files with 3 additions and 4 deletions

View File

@ -64,8 +64,6 @@ final class BlockStateUpgradeSchema{
*/ */
public array $remappedStates = []; public array $remappedStates = [];
private ?bool $backwardsCompatible = null;
public function __construct( public function __construct(
public int $maxVersionMajor, public int $maxVersionMajor,
public int $maxVersionMinor, public int $maxVersionMinor,

View File

@ -52,7 +52,7 @@ class BlockStateUpgraderTest extends TestCase{
} }
private function getNewSchemaVersion(int $versionId) : BlockStateUpgradeSchema{ private function getNewSchemaVersion(int $versionId) : BlockStateUpgradeSchema{
$schema = new BlockStateUpgradeSchema(($versionId >> 24) & 0xff, ($versionId >> 16) & 0xff, ($versionId >> 8) & 0xff, $versionId & 0xff); $schema = new BlockStateUpgradeSchema(($versionId >> 24) & 0xff, ($versionId >> 16) & 0xff, ($versionId >> 8) & 0xff, $versionId & 0xff, 0);
$this->upgrader->addSchema($schema); $this->upgrader->addSchema($schema);
return $schema; return $schema;
} }

View File

@ -208,7 +208,8 @@ function generateBlockStateUpgradeSchema(array $upgradeTable) : BlockStateUpgrad
($foundVersion >> 24) & 0xff, ($foundVersion >> 24) & 0xff,
($foundVersion >> 16) & 0xff, ($foundVersion >> 16) & 0xff,
($foundVersion >> 8) & 0xff, ($foundVersion >> 8) & 0xff,
($foundVersion & 0xff) ($foundVersion & 0xff),
0
); );
foreach(Utils::stringifyKeys($upgradeTable) as $oldName => $blockStateMappings){ foreach(Utils::stringifyKeys($upgradeTable) as $oldName => $blockStateMappings){
$newNameFound = []; $newNameFound = [];