mirror of
https://github.com/ReVanced/revanced-patcher.git
synced 2026-01-19 09:23:56 +00:00
fix: clear method lookup maps before initializing them (#210)
Co-authored-by: oSumAtrIX <johan.melkonyan1@web.de>
This commit is contained in:
@@ -392,4 +392,4 @@ class Patcher(private val options: PatcherOptions) {
|
|||||||
* @param patchInstance The instance of the [Patch] that was applied.
|
* @param patchInstance The instance of the [Patch] that was applied.
|
||||||
* @param success The result of the [Patch].
|
* @param success The result of the [Patch].
|
||||||
*/
|
*/
|
||||||
internal data class ExecutedPatch(val patchInstance: Patch<Context>, val success: Boolean)
|
internal data class ExecutedPatch(val patchInstance: Patch<Context>, val success: Boolean)
|
||||||
|
|||||||
@@ -99,7 +99,7 @@ abstract class MethodFingerprint(
|
|||||||
methodClassPairs!!.add(methodClassPair)
|
methodClassPairs!!.add(methodClassPair)
|
||||||
}
|
}
|
||||||
|
|
||||||
if (methods.isNotEmpty()) throw PatchResultError("Map already initialized")
|
if (methods.isNotEmpty()) MethodFingerprint.clearFingerprintResolutionLookupMaps()
|
||||||
|
|
||||||
context.classes.classes.forEach { classDef ->
|
context.classes.classes.forEach { classDef ->
|
||||||
classDef.methods.forEach { method ->
|
classDef.methods.forEach { method ->
|
||||||
@@ -510,4 +510,4 @@ data class MethodFingerprintResult(
|
|||||||
)
|
)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user