From 132bd5dec7fdd8fcfab20b789449de04e71dcf5e Mon Sep 17 00:00:00 2001 From: inotia00 <108592928+inotia00@users.noreply.github.com> Date: Sun, 22 Dec 2024 16:16:54 +0900 Subject: [PATCH] fix(YouTube - Shorts components): Patch failing during building with certain patch selection https://github.com/inotia00/ReVanced_Extended/issues/2581 --- .../youtube/shorts/components/ShortsComponentPatch.kt | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/patches/src/main/kotlin/app/revanced/patches/youtube/shorts/components/ShortsComponentPatch.kt b/patches/src/main/kotlin/app/revanced/patches/youtube/shorts/components/ShortsComponentPatch.kt index 34402150f..76363b6df 100644 --- a/patches/src/main/kotlin/app/revanced/patches/youtube/shorts/components/ShortsComponentPatch.kt +++ b/patches/src/main/kotlin/app/revanced/patches/youtube/shorts/components/ShortsComponentPatch.kt @@ -28,6 +28,7 @@ import app.revanced.patches.youtube.utils.lottie.lottieAnimationViewHookPatch import app.revanced.patches.youtube.utils.mainactivity.mainActivityResolvePatch import app.revanced.patches.youtube.utils.navigation.addBottomBarContainerHook import app.revanced.patches.youtube.utils.navigation.navigationBarHookPatch +import app.revanced.patches.youtube.utils.patch.PatchList.HIDE_FEED_FLYOUT_MENU import app.revanced.patches.youtube.utils.patch.PatchList.SHORTS_COMPONENTS import app.revanced.patches.youtube.utils.playertype.playerTypeHookPatch import app.revanced.patches.youtube.utils.playservice.is_18_31_or_greater @@ -315,11 +316,8 @@ private val shortsCustomActionsPatch = bytecodePatch( val insertIndex = charSequenceIndex + 2 - if (getInstruction(insertIndex).reference.toString() - .startsWith("Lapp/revanced") - ) { + if (HIDE_FEED_FLYOUT_MENU.included == true) removeInstructions(insertIndex, 2) - } addInstructions( insertIndex, """