mirror of
https://github.com/revanced/revanced-cli.git
synced 2025-02-23 07:41:10 +01:00
chore: merge nested if blocks
This commit is contained in:
parent
7dabd53109
commit
00145f2bb6
@ -24,13 +24,11 @@ fun Patcher.addPatchesFiltered(
|
||||
|
||||
val prefix = "[skipped] $patchName"
|
||||
|
||||
val args = MainCommand.args.pArgs!!
|
||||
val args = MainCommand.args.pArgs!!
|
||||
|
||||
if (excludePatches) {
|
||||
if (args.excludedPatches.contains(patchName)) {
|
||||
println("$prefix: Explicitly excluded.")
|
||||
return@patch
|
||||
}
|
||||
if (excludePatches && args.excludedPatches.contains(patchName)) {
|
||||
println("$prefix: Explicitly excluded.")
|
||||
return@patch
|
||||
} else if (!patch.include) {
|
||||
println("$prefix: Implicitly excluded.")
|
||||
return@patch
|
||||
@ -43,7 +41,7 @@ fun Patcher.addPatchesFiltered(
|
||||
return@patch
|
||||
}
|
||||
|
||||
if (!(args.experimental || compatiblePackages.any { it.versions.isEmpty() || it.versions.any { version -> version == packageVersion }})) {
|
||||
if (!(args.experimental || compatiblePackages.any { it.versions.isEmpty() || it.versions.any { version -> version == packageVersion } })) {
|
||||
println("$prefix: The package version is $packageVersion and is incompatible.")
|
||||
return@patch
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user