From dd34e4efa65a906a3f3e2c1fa715f6fb01ac0b34 Mon Sep 17 00:00:00 2001 From: rhunk <101876869+rhunk@users.noreply.github.com> Date: Sun, 28 Jan 2024 12:31:34 +0100 Subject: [PATCH] fix: MessageLogger --- .../me/rhunk/snapenhance/features/impl/spying/MessageLogger.kt | 1 + 1 file changed, 1 insertion(+) diff --git a/app/src/main/kotlin/me/rhunk/snapenhance/features/impl/spying/MessageLogger.kt b/app/src/main/kotlin/me/rhunk/snapenhance/features/impl/spying/MessageLogger.kt index 1e19d3c09..b6797191a 100644 --- a/app/src/main/kotlin/me/rhunk/snapenhance/features/impl/spying/MessageLogger.kt +++ b/app/src/main/kotlin/me/rhunk/snapenhance/features/impl/spying/MessageLogger.kt @@ -113,6 +113,7 @@ class MessageLogger : Feature("MessageLogger", //serialize all properties of messageJsonObject and put in the message object messageInstance.javaClass.declaredFields.forEach { field -> + if (field.name != "mMessageContent" && field.name != "mMetadata") return@forEach field.isAccessible = true messageJsonObject[field.name]?.let { fieldValue -> field.set(messageInstance, context.gson.fromJson(fieldValue, field.type))