From c93186fb9700907e65f33442e88073783cc163de Mon Sep 17 00:00:00 2001 From: oSumAtrIX Date: Fri, 25 Aug 2023 02:26:27 +0200 Subject: [PATCH] feat: Check for missing integrations Check, if the integrations file exists at first. --- .../kotlin/app/revanced/cli/command/PatchCommand.kt | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/src/main/kotlin/app/revanced/cli/command/PatchCommand.kt b/src/main/kotlin/app/revanced/cli/command/PatchCommand.kt index 2c049c41..87bfcdae 100644 --- a/src/main/kotlin/app/revanced/cli/command/PatchCommand.kt +++ b/src/main/kotlin/app/revanced/cli/command/PatchCommand.kt @@ -130,7 +130,16 @@ internal object PatchCommand : Runnable { // region Prepare if (!apk.exists()) { - logger.severe("Input file ${apk.name} does not exist") + logger.severe("APK file ${apk.name} does not exist") + return + } + + integrations.filter { !it.exists() }.let { + if (it.isEmpty()) return@let + + it.forEach { integration -> + logger.severe("Integration file ${integration.name} does not exist") + } return }