PaperMC/patches
Bjarne Koll 1b174804c7 Return null in getRegistry(Class) for unknown type (#11422)
The Bukkit#getRegistry(Class) method contract specifies that it returns
null for unknown registry types. The current implementation however
requires the passed class to be mappable to a known registry key.

For types like Material, which have a SimpleRegistry in bukkit's
Registry interface, no server side registry exists and such the type
cannot be mapped to a registry key.

The commit correctly returns null for types that are not mappable to a
registry key instead of throwing a NullPointerException.
2024-09-21 19:57:08 +02:00
..
api Updated Upstream (Bukkit/CraftBukkit/Spigot) (#11405) 2024-09-15 21:39:53 +02:00
server Return null in getRegistry(Class) for unknown type (#11422) 2024-09-21 19:57:08 +02:00
unapplied/server Apply optimise collision checking in move packet handling patch 2024-08-16 06:56:13 -07:00