mirror of
https://hub.spigotmc.org/stash/scm/spigot/bukkit.git
synced 2025-08-31 22:22:49 +00:00
Add Objects.requireNonNull so that there are not marked as nullable
This commit is contained in:
parent
fceddab5bd
commit
e3e84e6920
1 changed files with 4 additions and 4 deletions
|
@ -144,13 +144,13 @@ public interface Registry<T extends Keyed> extends Iterable<T> {
|
|||
*
|
||||
* @see Structure
|
||||
*/
|
||||
Registry<Structure> STRUCTURE = Bukkit.getRegistry(Structure.class);
|
||||
Registry<Structure> STRUCTURE = Objects.requireNonNull(Bukkit.getRegistry(Structure.class), "No registry present for Structure. This is a bug.");
|
||||
/**
|
||||
* Server structure types.
|
||||
*
|
||||
* @see StructureType
|
||||
*/
|
||||
Registry<StructureType> STRUCTURE_TYPE = Bukkit.getRegistry(StructureType.class);
|
||||
Registry<StructureType> STRUCTURE_TYPE = Objects.requireNonNull(Bukkit.getRegistry(StructureType.class), "No registry present for StructureType. This is a bug.");
|
||||
/**
|
||||
* Sound keys.
|
||||
*
|
||||
|
@ -164,7 +164,7 @@ public interface Registry<T extends Keyed> extends Iterable<T> {
|
|||
*/
|
||||
@MinecraftExperimental
|
||||
@ApiStatus.Experimental
|
||||
Registry<TrimMaterial> TRIM_MATERIAL = Bukkit.getRegistry(TrimMaterial.class);
|
||||
Registry<TrimMaterial> TRIM_MATERIAL = Objects.requireNonNull(Bukkit.getRegistry(TrimMaterial.class), "No registry present for TrimMaterial. This is a bug.");
|
||||
/**
|
||||
* Trim patterns.
|
||||
*
|
||||
|
@ -172,7 +172,7 @@ public interface Registry<T extends Keyed> extends Iterable<T> {
|
|||
*/
|
||||
@MinecraftExperimental
|
||||
@ApiStatus.Experimental
|
||||
Registry<TrimPattern> TRIM_PATTERN = Bukkit.getRegistry(TrimPattern.class);
|
||||
Registry<TrimPattern> TRIM_PATTERN = Objects.requireNonNull(Bukkit.getRegistry(TrimPattern.class), "No registry present for TrimPattern. This is a bug.");
|
||||
/**
|
||||
* Villager profession.
|
||||
*
|
||||
|
|
Loading…
Add table
Reference in a new issue