From 6125269df0a0f1bf83f1465ee271627e6c4aabfb Mon Sep 17 00:00:00 2001 From: shedaniel Date: Thu, 28 Jan 2021 21:06:28 +0800 Subject: [PATCH] Fix translating methods Signed-off-by: shedaniel --- .../linkie/discord/commands/QueryTranslateMethodCommand.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/kotlin/me/shedaniel/linkie/discord/commands/QueryTranslateMethodCommand.kt b/src/main/kotlin/me/shedaniel/linkie/discord/commands/QueryTranslateMethodCommand.kt index b13a8d9..7e8bf6a 100644 --- a/src/main/kotlin/me/shedaniel/linkie/discord/commands/QueryTranslateMethodCommand.kt +++ b/src/main/kotlin/me/shedaniel/linkie/discord/commands/QueryTranslateMethodCommand.kt @@ -103,7 +103,7 @@ class QueryTranslateMethodCommand(private val source: Namespace, private val tar val obfDesc = sourceMethod.getObfMergedDesc(sourceMappings) val parentObfName = sourceClassParent.obfName.merged!! val targetClass = targetMappings.getClassByObfName(parentObfName) ?: return@inner - val targetMethod = targetClass.methods.firstOrNull { it.obfName.merged == obfName && it.getObfServerDesc(targetMappings) == obfDesc } ?: return@inner + val targetMethod = targetClass.methods.firstOrNull { it.obfName.merged == obfName && it.getObfMergedDesc(targetMappings) == obfDesc } ?: return@inner remappedMethods[MethodCompound( sourceClassParent.optimumName.onlyClass() + "#" + sourceMethod.optimumName, obfDesc