mirror of
https://github.com/ReVanced/revanced-patcher.git
synced 2024-11-12 18:04:24 +01:00
chore: Merge branch dev
to main
(#250)
This commit is contained in:
commit
129d84e108
3 changed files with 12 additions and 5 deletions
|
@ -1,3 +1,10 @@
|
||||||
|
## [16.0.2-dev.1](https://github.com/ReVanced/revanced-patcher/compare/v16.0.1...v16.0.2-dev.1) (2023-10-06)
|
||||||
|
|
||||||
|
|
||||||
|
### Performance Improvements
|
||||||
|
|
||||||
|
* Use a map to merge integrations classes ([6059d3c](https://github.com/ReVanced/revanced-patcher/commit/6059d3ca2685cb659023b171b95d4b9d279c6e53))
|
||||||
|
|
||||||
## [16.0.1](https://github.com/ReVanced/revanced-patcher/compare/v16.0.0...v16.0.1) (2023-10-05)
|
## [16.0.1](https://github.com/ReVanced/revanced-patcher/compare/v16.0.0...v16.0.1) (2023-10-05)
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
org.gradle.parallel = true
|
org.gradle.parallel = true
|
||||||
org.gradle.caching = true
|
org.gradle.caching = true
|
||||||
kotlin.code.style = official
|
kotlin.code.style = official
|
||||||
version = 16.0.1
|
version = 16.0.2-dev.1
|
||||||
|
|
|
@ -108,7 +108,8 @@ class BytecodeContext internal constructor(private val options: PatcherOptions)
|
||||||
|
|
||||||
logger.info("Merging integrations")
|
logger.info("Merging integrations")
|
||||||
|
|
||||||
// TODO: Multi-thread this.
|
val classMap = classes.associateBy { it.type }
|
||||||
|
|
||||||
this@Integrations.forEach { integrations ->
|
this@Integrations.forEach { integrations ->
|
||||||
MultiDexIO.readDexFile(
|
MultiDexIO.readDexFile(
|
||||||
true,
|
true,
|
||||||
|
@ -116,8 +117,8 @@ class BytecodeContext internal constructor(private val options: PatcherOptions)
|
||||||
null,
|
null,
|
||||||
null
|
null
|
||||||
).classes.forEach classDef@{ classDef ->
|
).classes.forEach classDef@{ classDef ->
|
||||||
val existingClass = classes.find { it.type == classDef.type } ?: run {
|
val existingClass = classMap[classDef.type] ?: run {
|
||||||
logger.fine("Merging $classDef")
|
logger.fine("Adding $classDef")
|
||||||
classes.add(classDef)
|
classes.add(classDef)
|
||||||
return@classDef
|
return@classDef
|
||||||
}
|
}
|
||||||
|
@ -131,7 +132,6 @@ class BytecodeContext internal constructor(private val options: PatcherOptions)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
clear()
|
clear()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue