mirror of
https://github.com/ReVanced/revanced-patcher.git
synced 2024-11-10 09:08:04 +01:00
fix: check if fingerprint string is substring of any string references
This commit is contained in:
parent
c391ca648b
commit
c5de9e2988
2 changed files with 2 additions and 2 deletions
|
@ -109,7 +109,7 @@ abstract class MethodFingerprint(
|
||||||
if (instruction.opcode.ordinal != Opcode.CONST_STRING.ordinal) return@forEachIndexed
|
if (instruction.opcode.ordinal != Opcode.CONST_STRING.ordinal) return@forEachIndexed
|
||||||
|
|
||||||
val string = ((instruction as ReferenceInstruction).reference as StringReference).string
|
val string = ((instruction as ReferenceInstruction).reference as StringReference).string
|
||||||
val index = stringsList.indexOfFirst { it == string }
|
val index = stringsList.indexOfFirst(string::contains)
|
||||||
if (index == -1) return@forEachIndexed
|
if (index == -1) return@forEachIndexed
|
||||||
|
|
||||||
add(
|
add(
|
||||||
|
|
|
@ -14,7 +14,7 @@ import kotlin.reflect.KClass
|
||||||
annotation class Patch(val include: Boolean = true)
|
annotation class Patch(val include: Boolean = true)
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Annotation for dependencies of [Patch]es .
|
* Annotation for dependencies of [Patch]es.
|
||||||
*/
|
*/
|
||||||
@Target(AnnotationTarget.CLASS)
|
@Target(AnnotationTarget.CLASS)
|
||||||
@Retention(AnnotationRetention.RUNTIME)
|
@Retention(AnnotationRetention.RUNTIME)
|
||||||
|
|
Loading…
Reference in a new issue