mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-10-18 12:04:46 +00:00
Migrate all but two remaining legacy enums to native PHP 8.1 enums
This commit is contained in:
@@ -510,7 +510,7 @@ final class ItemSerializerDeserializerRegistrar{
|
||||
* complex to implement in a generic way.
|
||||
*/
|
||||
private function registerMiscItemMappings() : void{
|
||||
foreach(DyeColor::getAll() as $color){
|
||||
foreach(DyeColor::cases() as $color){
|
||||
$id = DyeColorIdMap::getInstance()->toItemId($color);
|
||||
$this->deserializer?->map($id, fn() => Items::DYE()->setColor($color));
|
||||
}
|
||||
|
Reference in New Issue
Block a user