From 3becdf52ecc2623b6d1ad5fd2195a2ee674a2c76 Mon Sep 17 00:00:00 2001 From: Hocuri Date: Fri, 30 Jun 2023 16:29:08 +0200 Subject: [PATCH] Fix crash in the "Full Msg" view by downgrading Gson (#2610) --- build.gradle | 2 +- src/com/b44t/messenger/rpc/Rpc.java | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/build.gradle b/build.gradle index 3b97c8190..ae37d2199 100644 --- a/build.gradle +++ b/build.gradle @@ -36,7 +36,7 @@ dependencies { implementation 'androidx.constraintlayout:constraintlayout:2.1.4' implementation 'com.journeyapps:zxing-android-embedded:3.4.0' // QR Code scanner implementation 'com.fasterxml.jackson.core:jackson-databind:2.11.1' // used as JSON library - implementation 'com.google.code.gson:gson:2.10.1' // used as JSON library + implementation 'com.google.code.gson:gson:2.9.1' // used as JSON library. Don't upgrade to 2.10.1: https://github.com/deltachat/deltachat-android/pull/2610 implementation "me.leolin:ShortcutBadger:1.1.16" // display messagecount on the home screen icon. implementation 'com.jpardogo.materialtabstrip:library:1.0.9' // used in the emoji selector for the tab selection. implementation 'com.github.chrisbanes:PhotoView:2.1.3' // does the zooming on photos / media diff --git a/src/com/b44t/messenger/rpc/Rpc.java b/src/com/b44t/messenger/rpc/Rpc.java index fcc862161..8f255c68c 100644 --- a/src/com/b44t/messenger/rpc/Rpc.java +++ b/src/com/b44t/messenger/rpc/Rpc.java @@ -93,7 +93,7 @@ public class Rpc { public Map getSystemInfo() throws RpcException { TypeToken> mapType = new TypeToken>(){}; - return gson.fromJson(getResult("get_system_info"), mapType); + return gson.fromJson(getResult("get_system_info"), mapType.getType()); } public HttpResponse getHttpResponse(int accountId, String url) throws RpcException {