diff --git a/src/main/kotlin/app/revanced/patcher/Patcher.kt b/src/main/kotlin/app/revanced/patcher/Patcher.kt index 3bf2359..e90dfce 100644 --- a/src/main/kotlin/app/revanced/patcher/Patcher.kt +++ b/src/main/kotlin/app/revanced/patcher/Patcher.kt @@ -100,9 +100,10 @@ class Patcher( * Apply patches loaded into the patcher. * @param stopOnError If true, the patches will stop on the first error. */ - fun applyPatches(stopOnError: Boolean = false): Map> { + fun applyPatches(stopOnError: Boolean = false, callback: (String) -> Unit = {}): Map> { return buildMap { for (patch in patches) { + callback(patch.patchName) val result: Result = try { val pr = patch.execute(cache) if (pr.isSuccess()) {