From 84a97a765c6b7e047e6fddd62e3c6036caea4f1b Mon Sep 17 00:00:00 2001 From: Aikar Date: Thu, 28 Apr 2016 00:57:27 -0400 Subject: [PATCH] remove null possibility for getServer singleton to stop IDE complaining about potential NPE diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java index 815b8dc243..5a04e6d72e 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java @@ -68,6 +68,7 @@ import org.spigotmc.SlackActivityAccountant; // Spigot public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant implements IMojangStatistics, ICommandListener, AutoCloseable, Runnable { + private static MinecraftServer SERVER; // Paper public static final Logger LOGGER = LogManager.getLogger(); public static final File b = new File("usercache.json"); private static final CompletableFuture i = CompletableFuture.completedFuture(Unit.INSTANCE); @@ -175,6 +176,7 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant(ResourcePackLoader::new); this.ai = new CraftingManager(); this.aj = new TagRegistry(); @@ -2122,7 +2124,7 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant