diff --git a/CHANGELOG.md b/CHANGELOG.md
index 708042836..cfa6b4f29 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,3 +1,16 @@
+# [2.145.0-dev.1](https://github.com/revanced/revanced-patches/compare/v2.144.0...v2.145.0-dev.1) (2022-12-18)
+
+
+### Bug Fixes
+
+* **tiktok/settings:** make compatible with newer versions ([c88740d](https://github.com/revanced/revanced-patches/commit/c88740dc2bf040747d9704d5bed52a7b533c22d6))
+
+
+### Features
+
+* **crunchyroll:** remove `enable-downloads` patch ([2ac1546](https://github.com/revanced/revanced-patches/commit/2ac15460f5734fc2c6d2d78d34083a8e6b2f7012))
+* **youtube-music:** bump compatibility to 5.36.51 ([c4a3099](https://github.com/revanced/revanced-patches/commit/c4a3099c1ca39431fba9beb94cc2b43e260561d9))
+
# [2.144.0](https://github.com/revanced/revanced-patches/compare/v2.143.0...v2.144.0) (2022-12-15)
diff --git a/README.md b/README.md
index be18b50f7..1e3e885e3 100644
--- a/README.md
+++ b/README.md
@@ -63,16 +63,16 @@ The official Patch bundle provided by ReVanced and the community.
| 💊 Patch | 📜 Description | 🏹 Target Version |
|:--------:|:--------------:|:-----------------:|
-| `background-play` | Enables playing music in the background. | 5.34.51 |
-| `codecs-unlock` | Adds more audio codec options. The new audio codecs usually result in better audio quality. | 5.34.51 |
-| `compact-header` | Hides the music category bar at the top of the homepage. | 5.34.51 |
-| `exclusive-audio-playback` | Enables the option to play music without video. | 5.34.51 |
-| `hide-get-premium` | Removes all "Get Premium" evidences from the avatar menu. | 5.34.51 |
-| `minimized-playback-music` | Enables minimized playback on Kids music. | 5.34.51 |
-| `music-microg-support` | Allows YouTube Music ReVanced to run without root and under a different package name. | 5.34.51 |
-| `music-video-ads` | Removes ads in the music player. | 5.34.51 |
-| `tasteBuilder-remover` | Removes the "Tell us which artists you like" card from the home screen. | 5.34.51 |
-| `upgrade-button-remover` | Removes the upgrade tab from the pivot bar. | 5.34.51 |
+| `background-play` | Enables playing music in the background. | 5.36.51 |
+| `codecs-unlock` | Adds more audio codec options. The new audio codecs usually result in better audio quality. | 5.36.51 |
+| `compact-header` | Hides the music category bar at the top of the homepage. | 5.36.51 |
+| `exclusive-audio-playback` | Enables the option to play music without video. | 5.36.51 |
+| `hide-get-premium` | Removes all "Get Premium" evidences from the avatar menu. | 5.36.51 |
+| `minimized-playback-music` | Enables minimized playback on Kids music. | 5.36.51 |
+| `music-microg-support` | Allows YouTube Music ReVanced to run without root and under a different package name. | 5.36.51 |
+| `music-video-ads` | Removes ads in the music player. | 5.36.51 |
+| `tasteBuilder-remover` | Removes the "Tell us which artists you like" card from the home screen. | 5.36.51 |
+| `upgrade-button-remover` | Removes the upgrade tab from the pivot bar. | 5.36.51 |
### [📦 `com.ss.android.ugc.trill`](https://play.google.com/store/apps/details?id=com.ss.android.ugc.trill)
@@ -86,7 +86,7 @@ The official Patch bundle provided by ReVanced and the community.
| `fix-google-login` | Allows logging in with a Google account. | all |
| `hide-ads` | Removes ads from TikTok. | all |
| `playback-speed` | Enables the playback speed option for all videos. | all |
-| `settings` | Adds settings for ReVanced to TikTok. | all |
+| `settings` | Adds ReVanced settings to TikTok. | all |
| `show-seekbar` | Shows progress bar for all video. | all |
| `sim-spoof` | Spoofs the information which is retrieved from the sim-card. | all |
@@ -102,7 +102,7 @@ The official Patch bundle provided by ReVanced and the community.
| `fix-google-login` | Allows logging in with a Google account. | all |
| `hide-ads` | Removes ads from TikTok. | all |
| `playback-speed` | Enables the playback speed option for all videos. | all |
-| `settings` | Adds settings for ReVanced to TikTok. | all |
+| `settings` | Adds ReVanced settings to TikTok. | all |
| `show-seekbar` | Shows progress bar for all video. | all |
| `sim-spoof` | Spoofs the information which is retrieved from the sim-card. | all |
@@ -165,14 +165,6 @@ The official Patch bundle provided by ReVanced and the community.
| `disable-ads` | Disables ads in HexEditor. | all |
-### [📦 `com.crunchyroll.crunchyroid`](https://play.google.com/store/apps/details?id=com.crunchyroll.crunchyroid)
-
-
-| 💊 Patch | 📜 Description | 🏹 Target Version |
-|:--------:|:--------------:|:-----------------:|
-| `enable-downloads` | Enables downloads for Crunchyroll. | all |
-
-
### [📦 `org.citra.citra_emu`](https://play.google.com/store/apps/details?id=org.citra.citra_emu)
diff --git a/gradle.properties b/gradle.properties
index 0ab24ef72..45734672f 100644
--- a/gradle.properties
+++ b/gradle.properties
@@ -1,2 +1,2 @@
kotlin.code.style = official
-version = 2.144.0
+version = 2.145.0-dev.1
diff --git a/src/main/kotlin/app/revanced/patches/crunchyroll/downloads/annotations/DownloadsCompatibility.kt b/src/main/kotlin/app/revanced/patches/crunchyroll/downloads/annotations/DownloadsCompatibility.kt
deleted file mode 100644
index deb5d7859..000000000
--- a/src/main/kotlin/app/revanced/patches/crunchyroll/downloads/annotations/DownloadsCompatibility.kt
+++ /dev/null
@@ -1,13 +0,0 @@
-package app.revanced.patches.crunchyroll.downloads.annotations
-
-import app.revanced.patcher.annotation.Compatibility
-import app.revanced.patcher.annotation.Package
-
-@Compatibility(
- [
- Package("com.crunchyroll.crunchyroid")
- ]
-)
-@Target(AnnotationTarget.CLASS)
-@Retention(AnnotationRetention.RUNTIME)
-internal annotation class DownloadsCompatibility
\ No newline at end of file
diff --git a/src/main/kotlin/app/revanced/patches/crunchyroll/downloads/fingerprints/DownloadsFingerprint.kt b/src/main/kotlin/app/revanced/patches/crunchyroll/downloads/fingerprints/DownloadsFingerprint.kt
deleted file mode 100644
index 12bfec818..000000000
--- a/src/main/kotlin/app/revanced/patches/crunchyroll/downloads/fingerprints/DownloadsFingerprint.kt
+++ /dev/null
@@ -1,23 +0,0 @@
-package app.revanced.patches.crunchyroll.downloads.fingerprints
-
-import app.revanced.patcher.annotation.Name
-import app.revanced.patcher.annotation.Version
-import app.revanced.patcher.extensions.or
-import app.revanced.patcher.fingerprint.method.impl.MethodFingerprint
-import app.revanced.patches.crunchyroll.downloads.annotations.DownloadsCompatibility
-import org.jf.dexlib2.AccessFlags
-import org.jf.dexlib2.Opcode
-
-@Name("downloads-fingerprint")
-@DownloadsCompatibility
-@Version("0.0.1")
-object DownloadsFingerprint : MethodFingerprint(
- "Z", AccessFlags.PUBLIC or AccessFlags.FINAL, null,
- opcodes = listOf(
- Opcode.CONST_STRING,
- Opcode.INVOKE_VIRTUAL,
- Opcode.MOVE_RESULT,
- Opcode.RETURN
- ),
- strings = listOf("offline_viewing"),
-)
\ No newline at end of file
diff --git a/src/main/kotlin/app/revanced/patches/crunchyroll/downloads/patch/DownloadsPatch.kt b/src/main/kotlin/app/revanced/patches/crunchyroll/downloads/patch/DownloadsPatch.kt
deleted file mode 100644
index 8b9f50859..000000000
--- a/src/main/kotlin/app/revanced/patches/crunchyroll/downloads/patch/DownloadsPatch.kt
+++ /dev/null
@@ -1,37 +0,0 @@
-package app.revanced.patches.crunchyroll.downloads.patch
-
-import app.revanced.patcher.annotation.Description
-import app.revanced.patcher.annotation.Name
-import app.revanced.patcher.annotation.Version
-import app.revanced.patcher.data.BytecodeContext
-import app.revanced.patcher.extensions.replaceInstruction
-import app.revanced.patcher.patch.BytecodePatch
-import app.revanced.patcher.patch.PatchResult
-import app.revanced.patcher.patch.PatchResultSuccess
-import app.revanced.patcher.patch.annotations.Patch
-import app.revanced.patches.crunchyroll.downloads.annotations.DownloadsCompatibility
-import app.revanced.patches.crunchyroll.downloads.fingerprints.DownloadsFingerprint
-
-@Patch
-@Name("enable-downloads")
-@Description("Enables downloads for Crunchyroll.")
-@DownloadsCompatibility
-@Version("0.0.1")
-class DownloadsPatch : BytecodePatch(
- listOf(
- DownloadsFingerprint
- )
-) {
- override fun execute(context: BytecodeContext): PatchResult {
- with(DownloadsFingerprint.result!!.mutableMethod) {
- val index = implementation!!.instructions.lastIndex
- replaceInstruction(
- index - 1,
- """
- const/4 v0, 0x1
- """
- )
- }
- return PatchResultSuccess()
- }
-}
\ No newline at end of file
diff --git a/src/main/kotlin/app/revanced/patches/music/ad/video/annotations/MusicVideoAdsCompatibility.kt b/src/main/kotlin/app/revanced/patches/music/ad/video/annotations/MusicVideoAdsCompatibility.kt
index 6b553561c..314e1597e 100644
--- a/src/main/kotlin/app/revanced/patches/music/ad/video/annotations/MusicVideoAdsCompatibility.kt
+++ b/src/main/kotlin/app/revanced/patches/music/ad/video/annotations/MusicVideoAdsCompatibility.kt
@@ -20,7 +20,8 @@ import app.revanced.patcher.annotation.Package
"5.28.52",
"5.29.52",
"5.31.50",
- "5.34.51"
+ "5.34.51",
+ "5.36.51"
)
)]
)
diff --git a/src/main/kotlin/app/revanced/patches/music/audio/codecs/annotations/CodecsUnlockCompatibility.kt b/src/main/kotlin/app/revanced/patches/music/audio/codecs/annotations/CodecsUnlockCompatibility.kt
index 0bf3e005e..5fd4bca7f 100644
--- a/src/main/kotlin/app/revanced/patches/music/audio/codecs/annotations/CodecsUnlockCompatibility.kt
+++ b/src/main/kotlin/app/revanced/patches/music/audio/codecs/annotations/CodecsUnlockCompatibility.kt
@@ -20,7 +20,8 @@ import app.revanced.patcher.annotation.Package
"5.28.52",
"5.29.52",
"5.31.50",
- "5.34.51"
+ "5.34.51",
+ "5.36.51"
)
)]
)
diff --git a/src/main/kotlin/app/revanced/patches/music/audio/exclusiveaudio/annotations/ExclusiveAudioCompatibility.kt b/src/main/kotlin/app/revanced/patches/music/audio/exclusiveaudio/annotations/ExclusiveAudioCompatibility.kt
index 5eb3e060b..a653e57f9 100644
--- a/src/main/kotlin/app/revanced/patches/music/audio/exclusiveaudio/annotations/ExclusiveAudioCompatibility.kt
+++ b/src/main/kotlin/app/revanced/patches/music/audio/exclusiveaudio/annotations/ExclusiveAudioCompatibility.kt
@@ -20,7 +20,8 @@ import app.revanced.patcher.annotation.Package
"5.28.52",
"5.29.52",
"5.31.50",
- "5.34.51"
+ "5.34.51",
+ "5.36.51"
)
)]
)
diff --git a/src/main/kotlin/app/revanced/patches/music/layout/compactheader/annotations/CompactHeaderCompatibility.kt b/src/main/kotlin/app/revanced/patches/music/layout/compactheader/annotations/CompactHeaderCompatibility.kt
index 3800a7c14..a54a37194 100644
--- a/src/main/kotlin/app/revanced/patches/music/layout/compactheader/annotations/CompactHeaderCompatibility.kt
+++ b/src/main/kotlin/app/revanced/patches/music/layout/compactheader/annotations/CompactHeaderCompatibility.kt
@@ -19,7 +19,8 @@ import app.revanced.patcher.annotation.Package
"5.28.52",
"5.29.52",
"5.31.50",
- "5.34.51"
+ "5.34.51",
+ "5.36.51"
)
)]
)
diff --git a/src/main/kotlin/app/revanced/patches/music/layout/minimizedplayback/annotations/MinimizedPlaybackCompatibility.kt b/src/main/kotlin/app/revanced/patches/music/layout/minimizedplayback/annotations/MinimizedPlaybackCompatibility.kt
index 2a575b411..b5ec0f5b6 100644
--- a/src/main/kotlin/app/revanced/patches/music/layout/minimizedplayback/annotations/MinimizedPlaybackCompatibility.kt
+++ b/src/main/kotlin/app/revanced/patches/music/layout/minimizedplayback/annotations/MinimizedPlaybackCompatibility.kt
@@ -20,7 +20,8 @@ import app.revanced.patcher.annotation.Package
"5.28.52",
"5.29.52",
"5.31.50",
- "5.34.51"
+ "5.34.51",
+ "5.36.51"
)
)]
)
diff --git a/src/main/kotlin/app/revanced/patches/music/layout/premium/annotations/HideGetPremiumCompatibility.kt b/src/main/kotlin/app/revanced/patches/music/layout/premium/annotations/HideGetPremiumCompatibility.kt
index 598fc8714..f2089df2a 100644
--- a/src/main/kotlin/app/revanced/patches/music/layout/premium/annotations/HideGetPremiumCompatibility.kt
+++ b/src/main/kotlin/app/revanced/patches/music/layout/premium/annotations/HideGetPremiumCompatibility.kt
@@ -20,7 +20,8 @@ import app.revanced.patcher.annotation.Package
"5.28.52",
"5.29.52",
"5.31.50",
- "5.34.51"
+ "5.34.51",
+ "5.36.51"
)
)]
)
diff --git a/src/main/kotlin/app/revanced/patches/music/layout/tastebuilder/annotations/RemoveTasteBuilderCompatibility.kt b/src/main/kotlin/app/revanced/patches/music/layout/tastebuilder/annotations/RemoveTasteBuilderCompatibility.kt
index eb55fb3b6..c51a2f11d 100644
--- a/src/main/kotlin/app/revanced/patches/music/layout/tastebuilder/annotations/RemoveTasteBuilderCompatibility.kt
+++ b/src/main/kotlin/app/revanced/patches/music/layout/tastebuilder/annotations/RemoveTasteBuilderCompatibility.kt
@@ -22,7 +22,8 @@ import app.revanced.patcher.annotation.Package
"5.28.52",
"5.29.52",
"5.31.50",
- "5.34.51"
+ "5.34.51",
+ "5.36.51"
)
)]
)
diff --git a/src/main/kotlin/app/revanced/patches/music/layout/upgradebutton/annotations/RemoveUpgradeButtonCompatibility.kt b/src/main/kotlin/app/revanced/patches/music/layout/upgradebutton/annotations/RemoveUpgradeButtonCompatibility.kt
index d9aec6962..b949a4a5d 100644
--- a/src/main/kotlin/app/revanced/patches/music/layout/upgradebutton/annotations/RemoveUpgradeButtonCompatibility.kt
+++ b/src/main/kotlin/app/revanced/patches/music/layout/upgradebutton/annotations/RemoveUpgradeButtonCompatibility.kt
@@ -20,7 +20,8 @@ import app.revanced.patcher.annotation.Package
"5.28.52",
"5.29.52",
"5.31.50",
- "5.34.51"
+ "5.34.51",
+ "5.36.51"
)
)]
)
diff --git a/src/main/kotlin/app/revanced/patches/music/misc/microg/annotations/MusicMicroGPatchCompatibility.kt b/src/main/kotlin/app/revanced/patches/music/misc/microg/annotations/MusicMicroGPatchCompatibility.kt
index d407da7a1..a4636a23e 100644
--- a/src/main/kotlin/app/revanced/patches/music/misc/microg/annotations/MusicMicroGPatchCompatibility.kt
+++ b/src/main/kotlin/app/revanced/patches/music/misc/microg/annotations/MusicMicroGPatchCompatibility.kt
@@ -20,7 +20,8 @@ import app.revanced.patcher.annotation.Package
"5.28.52",
"5.29.52",
"5.31.50",
- "5.34.51"
+ "5.34.51",
+ "5.36.51"
)
)]
)
diff --git a/src/main/kotlin/app/revanced/patches/music/premium/backgroundplay/annotations/BackgroundPlayCompatibility.kt b/src/main/kotlin/app/revanced/patches/music/premium/backgroundplay/annotations/BackgroundPlayCompatibility.kt
index 42e9d025f..0c91cb5bd 100644
--- a/src/main/kotlin/app/revanced/patches/music/premium/backgroundplay/annotations/BackgroundPlayCompatibility.kt
+++ b/src/main/kotlin/app/revanced/patches/music/premium/backgroundplay/annotations/BackgroundPlayCompatibility.kt
@@ -20,7 +20,8 @@ import app.revanced.patcher.annotation.Package
"5.28.52",
"5.29.52",
"5.31.50",
- "5.34.51"
+ "5.34.51",
+ "5.36.51"
)
)]
)
diff --git a/src/main/kotlin/app/revanced/patches/tiktok/misc/settings/fingerprints/AboutOnClickMethodFingerprint.kt b/src/main/kotlin/app/revanced/patches/tiktok/misc/settings/fingerprints/AboutOnClickMethodFingerprint.kt
deleted file mode 100644
index e4e8b16b4..000000000
--- a/src/main/kotlin/app/revanced/patches/tiktok/misc/settings/fingerprints/AboutOnClickMethodFingerprint.kt
+++ /dev/null
@@ -1,12 +0,0 @@
-package app.revanced.patches.tiktok.misc.settings.fingerprints
-
-import app.revanced.patcher.fingerprint.method.impl.MethodFingerprint
-
-object AboutOnClickMethodFingerprint : MethodFingerprint(
- strings = listOf(
- "//setting/about",
- "enter_from",
- "settings_page",
- "enter_settings_about"
- )
-)
\ No newline at end of file
diff --git a/src/main/kotlin/app/revanced/patches/tiktok/misc/settings/fingerprints/AboutViewFingerprint.kt b/src/main/kotlin/app/revanced/patches/tiktok/misc/settings/fingerprints/AboutViewFingerprint.kt
new file mode 100644
index 000000000..e734a6f13
--- /dev/null
+++ b/src/main/kotlin/app/revanced/patches/tiktok/misc/settings/fingerprints/AboutViewFingerprint.kt
@@ -0,0 +1,39 @@
+package app.revanced.patches.tiktok.misc.settings.fingerprints
+
+import app.revanced.patcher.fingerprint.method.annotation.FuzzyPatternScanMethod
+import app.revanced.patcher.fingerprint.method.impl.MethodFingerprint
+import org.jf.dexlib2.Opcode
+
+@FuzzyPatternScanMethod(4)
+object AboutViewFingerprint : MethodFingerprint(
+ opcodes = listOf(
+ Opcode.NEW_INSTANCE,
+ Opcode.INVOKE_DIRECT,
+ Opcode.MOVE,
+ Opcode.INVOKE_DIRECT_RANGE,
+ Opcode.INVOKE_DIRECT,
+ Opcode.IPUT_OBJECT,
+ Opcode.NEW_INSTANCE,
+ Opcode.NEW_INSTANCE,
+ Opcode.CONST,
+ Opcode.INVOKE_VIRTUAL,
+ Opcode.MOVE_RESULT_OBJECT,
+ Opcode.NEW_INSTANCE,
+ Opcode.INVOKE_DIRECT,
+ Opcode.INVOKE_STATIC,
+ Opcode.MOVE_RESULT_OBJECT,
+ Opcode.NEW_INSTANCE,
+ Opcode.INVOKE_DIRECT,
+ Opcode.CONST_4,
+ Opcode.CONST_STRING,
+ Opcode.INVOKE_DIRECT_RANGE,
+ Opcode.INVOKE_DIRECT,
+ Opcode.IPUT_OBJECT,
+ Opcode.CONST,
+ Opcode.SGET_OBJECT,
+ Opcode.INVOKE_VIRTUAL,
+ Opcode.MOVE_RESULT,
+ Opcode.IF_EQZ,
+ Opcode.CONST
+ )
+)
\ No newline at end of file
diff --git a/src/main/kotlin/app/revanced/patches/tiktok/misc/settings/patch/SettingsPatch.kt b/src/main/kotlin/app/revanced/patches/tiktok/misc/settings/patch/SettingsPatch.kt
index 20b9228e0..0fcd0943d 100644
--- a/src/main/kotlin/app/revanced/patches/tiktok/misc/settings/patch/SettingsPatch.kt
+++ b/src/main/kotlin/app/revanced/patches/tiktok/misc/settings/patch/SettingsPatch.kt
@@ -1,5 +1,6 @@
package app.revanced.patches.tiktok.misc.settings.patch
+import app.revanced.extensions.toErrorResult
import app.revanced.patcher.annotation.Description
import app.revanced.patcher.annotation.Name
import app.revanced.patcher.annotation.Version
@@ -7,6 +8,7 @@ import app.revanced.patcher.data.BytecodeContext
import app.revanced.patcher.extensions.addInstructions
import app.revanced.patcher.extensions.instruction
import app.revanced.patcher.extensions.replaceInstruction
+import app.revanced.patcher.fingerprint.method.impl.MethodFingerprint.Companion.resolve
import app.revanced.patcher.patch.BytecodePatch
import app.revanced.patcher.patch.PatchResult
import app.revanced.patcher.patch.PatchResultError
@@ -15,13 +17,12 @@ import app.revanced.patcher.patch.annotations.DependsOn
import app.revanced.patcher.patch.annotations.Patch
import app.revanced.patches.tiktok.misc.integrations.patch.IntegrationsPatch
import app.revanced.patches.tiktok.misc.settings.annotations.SettingsCompatibility
-import app.revanced.patches.tiktok.misc.settings.fingerprints.AboutOnClickMethodFingerprint
+import app.revanced.patches.tiktok.misc.settings.fingerprints.AboutViewFingerprint
import app.revanced.patches.tiktok.misc.settings.fingerprints.AdPersonalizationActivityOnCreateFingerprint
import app.revanced.patches.tiktok.misc.settings.fingerprints.SettingsOnViewCreatedFingerprint
import org.jf.dexlib2.Opcode
import org.jf.dexlib2.iface.instruction.OneRegisterInstruction
import org.jf.dexlib2.iface.instruction.ReferenceInstruction
-import org.jf.dexlib2.iface.instruction.formats.Instruction21c
import org.jf.dexlib2.iface.instruction.formats.Instruction35c
import org.jf.dexlib2.iface.reference.StringReference
import org.jf.dexlib2.iface.reference.TypeReference
@@ -29,17 +30,19 @@ import org.jf.dexlib2.iface.reference.TypeReference
@Patch
@DependsOn([IntegrationsPatch::class])
@Name("settings")
-@Description("Adds settings for ReVanced to TikTok.")
+@Description("Adds ReVanced settings to TikTok.")
@SettingsCompatibility
@Version("0.0.1")
class SettingsPatch : BytecodePatch(
listOf(
AdPersonalizationActivityOnCreateFingerprint,
SettingsOnViewCreatedFingerprint,
- AboutOnClickMethodFingerprint
)
) {
override fun execute(context: BytecodeContext): PatchResult {
+ SettingsOnViewCreatedFingerprint.result?.let {
+ AboutViewFingerprint.resolve(context, it.method, it.classDef)
+ }
// Patch Settings UI to add 'Revanced Settings'.
val targetIndexes = findOptionsOnClickIndex()
with(SettingsOnViewCreatedFingerprint.result!!.mutableMethod) {
@@ -72,29 +75,21 @@ class SettingsPatch : BytecodePatch(
private fun findOptionsOnClickIndex(): IntArray {
val results = IntArray(2)
- var found = 0
- with(SettingsOnViewCreatedFingerprint.result!!.mutableMethod) {
- for ((index, instruction) in implementation!!.instructions.withIndex()) {
+ SettingsOnViewCreatedFingerprint.result?.apply {
+ for ((index, instruction) in mutableMethod.implementation!!.instructions.withIndex()) {
// Old UI settings option to replace to 'Revanced Settings'
if (instruction.opcode == Opcode.CONST_STRING) {
val string = ((instruction as ReferenceInstruction).reference as StringReference).string
if (string == "copyright_policy") {
results[0] = index - 2
- found++
+ break
}
}
-
- // New UI settings option to replace to 'Revanced Settings'
- if (instruction.opcode == Opcode.NEW_INSTANCE) {
- val onClickClass = ((instruction as Instruction21c).reference as TypeReference).type
- if (onClickClass == AboutOnClickMethodFingerprint.result!!.mutableMethod.definingClass) {
- results[1] = index
- found++
- }
- }
- if (found > 1) break
}
- }
+
+ // New UI settings option to replace to 'Revanced Settings'
+ results[1] = AboutViewFingerprint.result!!.scanResult.patternScanResult!!.startIndex
+ } ?: throw SettingsOnViewCreatedFingerprint.toErrorResult()
return results
}