Skip to content

Commit

Permalink
style(gradle-plugin): Reformat code fluently to reduce indentation
Browse files Browse the repository at this point in the history
Signed-off-by: Sebastian Schuberth <[email protected]>
  • Loading branch information
sschuberth committed Mar 15, 2024
1 parent 3c83d5f commit 0ddcfe4
Showing 1 changed file with 6 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -167,11 +167,12 @@ internal class OrtModelBuilder : ToolingModelBuilder {
when (val id = selectedComponent.id) {
is ModuleComponentIdentifier -> {
val pomFile = if (selectedComponent is ResolvedComponentResultInternal) {
val repositoryId = runCatching { selectedComponent.repositoryId }
.recoverCatching {
@Suppress("DEPRECATION")
selectedComponent.repositoryName
}.getOrNull()
val repositoryId = runCatching {
selectedComponent.repositoryId
}.recoverCatching {
@Suppress("DEPRECATION")
selectedComponent.repositoryName
}.getOrNull()

repositories[repositoryId]?.let { repositoryUrl ->
// Note: Only Maven-style layout is supported for now.
Expand Down

0 comments on commit 0ddcfe4

Please sign in to comment.