Avoid redundant check for performance critical code

Dieser Commit ist enthalten in:
Jesse Boyd 2019-06-29 04:23:51 +10:00
Ursprung 58c6b6278f
Commit d6280ec945
Es konnte kein GPG-Schlüssel zu dieser Signatur gefunden werden
GPG-Schlüssel-ID: 59F1DE6293AF6E1F

Datei anzeigen

@ -200,7 +200,6 @@ public enum BukkitAdapter {
* @return The Bukkit Material * @return The Bukkit Material
*/ */
public static Material adapt(BlockType blockType) { public static Material adapt(BlockType blockType) {
checkNotNull(blockType);
return getAdapter().adapt(blockType); return getAdapter().adapt(blockType);
} }
@ -250,7 +249,6 @@ public enum BukkitAdapter {
* @return The blocktype * @return The blocktype
*/ */
public static BlockType asBlockType(Material material) { public static BlockType asBlockType(Material material) {
checkNotNull(material);
return getAdapter().asBlockType(material); return getAdapter().asBlockType(material);
} }
@ -273,7 +271,6 @@ public enum BukkitAdapter {
* @return The WorldEdit BlockState * @return The WorldEdit BlockState
*/ */
public static BlockState adapt(BlockData blockData) { public static BlockState adapt(BlockData blockData) {
checkNotNull(blockData);
return getAdapter().adapt(blockData); return getAdapter().adapt(blockData);
} }
@ -288,7 +285,6 @@ public enum BukkitAdapter {
* @return The Bukkit BlockData * @return The Bukkit BlockData
*/ */
public static BlockData adapt(BlockStateHolder block) { public static BlockData adapt(BlockStateHolder block) {
checkNotNull(block);
return getAdapter().adapt(block); return getAdapter().adapt(block);
} }