From 264bd514f53e9a2b5cee97b5d90e4f11aecddc9c Mon Sep 17 00:00:00 2001 From: Gravit Date: Sat, 13 Apr 2019 23:21:14 +0700 Subject: [PATCH] =?UTF-8?q?[FIX]=20=D0=97=D0=B0=D0=B1=D1=8B=D1=82=D1=8B?= =?UTF-8?q?=D0=B9=20=D0=B0=D0=B4=D0=B0=D0=BF=D1=82=D0=B5=D1=80=20hashedEnt?= =?UTF-8?q?ry?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/java/ru/gravit/launcher/LauncherEngine.java | 3 +++ .../main/java/ru/gravit/launcher/client/ClientLauncher.java | 5 ++--- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/Launcher/src/main/java/ru/gravit/launcher/LauncherEngine.java b/Launcher/src/main/java/ru/gravit/launcher/LauncherEngine.java index 6d0c8f9c..89e98d0e 100644 --- a/Launcher/src/main/java/ru/gravit/launcher/LauncherEngine.java +++ b/Launcher/src/main/java/ru/gravit/launcher/LauncherEngine.java @@ -7,6 +7,8 @@ import ru.gravit.launcher.guard.LauncherGuardManager; import ru.gravit.launcher.gui.JSRuntimeProvider; import ru.gravit.launcher.gui.RuntimeProvider; +import ru.gravit.launcher.hasher.HashedEntry; +import ru.gravit.launcher.hasher.HashedEntryAdapter; import ru.gravit.utils.helper.CommonHelper; import ru.gravit.utils.helper.EnvHelper; import ru.gravit.utils.helper.JVMHelper; @@ -41,6 +43,7 @@ public static void main(String... args) throws Throwable { public static void initGson() { if (Launcher.gson != null) return; Launcher.gsonBuilder = new GsonBuilder(); + Launcher.gsonBuilder.registerTypeAdapter(HashedEntry.class, new HashedEntryAdapter()); Launcher.gson = Launcher.gsonBuilder.create(); } diff --git a/Launcher/src/main/java/ru/gravit/launcher/client/ClientLauncher.java b/Launcher/src/main/java/ru/gravit/launcher/client/ClientLauncher.java index d62ae452..bf856d3f 100644 --- a/Launcher/src/main/java/ru/gravit/launcher/client/ClientLauncher.java +++ b/Launcher/src/main/java/ru/gravit/launcher/client/ClientLauncher.java @@ -5,9 +5,7 @@ import ru.gravit.launcher.*; import ru.gravit.launcher.guard.LauncherGuardManager; import ru.gravit.launcher.gui.JSRuntimeProvider; -import ru.gravit.launcher.hasher.DirWatcher; -import ru.gravit.launcher.hasher.FileNameMatcher; -import ru.gravit.launcher.hasher.HashedDir; +import ru.gravit.launcher.hasher.*; import ru.gravit.launcher.profiles.ClientProfile; import ru.gravit.launcher.profiles.PlayerProfile; import ru.gravit.launcher.request.Request; @@ -526,6 +524,7 @@ private static LinkedList resolveClassPathList(Path clientDir, String... c public static void initGson() { if (Launcher.gson != null) return; Launcher.gsonBuilder = new GsonBuilder(); + Launcher.gsonBuilder.registerTypeAdapter(HashedEntry.class, new HashedEntryAdapter()); Launcher.gson = Launcher.gsonBuilder.create(); }