mirror of
https://github.com/revanced/revanced-patches
synced 2024-12-02 23:22:57 +01:00
fix: incorrect cast of instruction
This commit is contained in:
parent
4347f88af0
commit
fb94a1cb48
@ -14,6 +14,7 @@ import app.revanced.patcher.patch.annotations.DependsOn
|
||||
import app.revanced.patcher.patch.annotations.Patch
|
||||
import app.revanced.patches.youtube.layout.hide.loadmorebutton.bytecode.fingerprints.HideLoadMoreButtonFingerprint
|
||||
import app.revanced.patches.youtube.layout.hide.loadmorebutton.resource.patch.HideLoadMoreButtonResourcePatch
|
||||
import org.jf.dexlib2.iface.instruction.OneRegisterInstruction
|
||||
import org.jf.dexlib2.iface.instruction.TwoRegisterInstruction
|
||||
|
||||
@Patch
|
||||
@ -26,7 +27,7 @@ class HideLoadMoreButtonPatch : BytecodePatch(listOf(HideLoadMoreButtonFingerpri
|
||||
HideLoadMoreButtonFingerprint.result?.let {
|
||||
it.mutableMethod.apply {
|
||||
val moveRegisterIndex = it.scanResult.patternScanResult!!.endIndex
|
||||
val viewRegister = instruction<TwoRegisterInstruction>(moveRegisterIndex).registerA
|
||||
val viewRegister = instruction<OneRegisterInstruction>(moveRegisterIndex).registerA
|
||||
|
||||
val insertIndex = moveRegisterIndex + 1
|
||||
addInstruction(
|
||||
|
Loading…
Reference in New Issue
Block a user