[FIX] Забытый адаптер hashedEntry

This commit is contained in:
Gravit 2019-04-13 23:21:14 +07:00
parent f7091bf074
commit 264bd514f5
No known key found for this signature in database
GPG key ID: 061981E1E85D3216
2 changed files with 5 additions and 3 deletions

View file

@ -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();
}

View file

@ -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<Path> 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();
}