mirror of
https://github.com/ReVanced/revanced-patches.git
synced 2024-11-10 01:01:56 +01:00
fix: multiple compatible pkgs on readme
This commit is contained in:
parent
6aede6049e
commit
3f82a1349f
1 changed files with 4 additions and 6 deletions
|
@ -17,13 +17,11 @@ fun generateText(bundle: Bundle) {
|
|||
val output = StringBuilder()
|
||||
val packages = mutableMapOf<String, MutableList<Class<out Patch<Data>>>>()
|
||||
|
||||
bundle.map {
|
||||
val packageName = it.compatiblePackages?.first()?.name!!
|
||||
if (!packages.contains(packageName)) {
|
||||
packages[packageName] = mutableListOf()
|
||||
for (patch in bundle) {
|
||||
patch.compatiblePackages?.forEach { pkg ->
|
||||
if (!packages.contains(pkg.name)) packages[pkg.name] = mutableListOf()
|
||||
packages[pkg.name]!!.add(patch)
|
||||
}
|
||||
|
||||
packages[packageName]?.add(it)
|
||||
}
|
||||
|
||||
for (pkg in packages) {
|
||||
|
|
Loading…
Reference in a new issue