From 37b679bbd6b1d42b79be3f6b4d413c1cdc494fe1 Mon Sep 17 00:00:00 2001 From: Gravit Date: Mon, 1 Jul 2019 17:08:20 +0700 Subject: [PATCH] =?UTF-8?q?[FIX]=20=D0=98=D1=81=D0=BF=D1=80=D0=B0=D0=B2?= =?UTF-8?q?=D0=BB=D0=B5=D0=BD=D0=B8=D0=B5=20=D0=BE=D1=88=D0=B8=D0=B1=D0=BE?= =?UTF-8?q?=D0=BA=20NPE=20=D0=BF=D1=80=D0=B8=20=D0=B7=D0=B0=D0=BF=D1=83?= =?UTF-8?q?=D1=81=D0=BA=D0=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/java/pro/gravit/launchserver/LaunchServer.java | 3 ++- .../gravit/launchserver/manangers/hook/AuthHookManager.java | 2 +- .../java/pro/gravit/launchserver/socket/WebSocketService.java | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/LaunchServer/src/main/java/pro/gravit/launchserver/LaunchServer.java b/LaunchServer/src/main/java/pro/gravit/launchserver/LaunchServer.java index 1fe39c8f..6db964b0 100644 --- a/LaunchServer/src/main/java/pro/gravit/launchserver/LaunchServer.java +++ b/LaunchServer/src/main/java/pro/gravit/launchserver/LaunchServer.java @@ -575,7 +575,8 @@ public LaunchServer(Path dir, boolean testEnv, String[] args) throws IOException } config.permissionsHandler.init(this); config.hwidHandler.init(); - config.dao.init(this); + if(config.dao != null) + config.dao.init(this); if (config.protectHandler != null) { config.protectHandler.checkLaunchServerLicense(); } diff --git a/LaunchServer/src/main/java/pro/gravit/launchserver/manangers/hook/AuthHookManager.java b/LaunchServer/src/main/java/pro/gravit/launchserver/manangers/hook/AuthHookManager.java index 31a7d451..739d4eda 100644 --- a/LaunchServer/src/main/java/pro/gravit/launchserver/manangers/hook/AuthHookManager.java +++ b/LaunchServer/src/main/java/pro/gravit/launchserver/manangers/hook/AuthHookManager.java @@ -27,5 +27,5 @@ public RegContext(String login, String password, String ip, boolean trustContext this.trustContext = trustContext; } } - public HookSet registraion; + public HookSet registraion = new HookSet<>(); } diff --git a/LaunchServer/src/main/java/pro/gravit/launchserver/socket/WebSocketService.java b/LaunchServer/src/main/java/pro/gravit/launchserver/socket/WebSocketService.java index a94b870f..41d1dc7b 100644 --- a/LaunchServer/src/main/java/pro/gravit/launchserver/socket/WebSocketService.java +++ b/LaunchServer/src/main/java/pro/gravit/launchserver/socket/WebSocketService.java @@ -44,7 +44,7 @@ @SuppressWarnings("rawtypes") public class WebSocketService { public final ChannelGroup channels; - public static ProviderMap providers; + public static ProviderMap providers = new ProviderMap<>(); public WebSocketService(ChannelGroup channels, LaunchServer server) { this.channels = channels;