From 0f5ec1c912aaabafd19371721423ba7b1e7d8fbb Mon Sep 17 00:00:00 2001 From: fankesyooni Date: Mon, 15 Aug 2022 01:57:06 +0800 Subject: [PATCH] Modify change injectModuleAppResources function code style --- .../yukihookapi/hook/xposed/parasitic/AppParasitics.kt | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/yukihookapi/src/api/kotlin/com/highcapable/yukihookapi/hook/xposed/parasitic/AppParasitics.kt b/yukihookapi/src/api/kotlin/com/highcapable/yukihookapi/hook/xposed/parasitic/AppParasitics.kt index 14c07097..c9182147 100644 --- a/yukihookapi/src/api/kotlin/com/highcapable/yukihookapi/hook/xposed/parasitic/AppParasitics.kt +++ b/yukihookapi/src/api/kotlin/com/highcapable/yukihookapi/hook/xposed/parasitic/AppParasitics.kt @@ -225,12 +225,7 @@ internal object AppParasitics { internal fun injectModuleAppResources(hostResources: Resources) { if (injectedHostResourcesHashCodes.contains(hostResources.hashCode())) return if (YukiHookBridge.hasXposedBridge) runCatching { - hostResources.assets.current { - method { - name = "addAssetPath" - param(StringType) - }.call(moduleAppFilePath) - } + hostResources.assets.current().method { name = "addAssetPath"; param(StringType) }.call(moduleAppFilePath) injectedHostResourcesHashCodes.add(hostResources.hashCode()) }.onFailure { yLoggerE(msg = "Failed to inject module resources into [$hostResources]", e = it)