Skip to content

Commit

Permalink
chore(stack): Move a function to the top level
Browse files Browse the repository at this point in the history
Improve the readability a bit.

Signed-off-by: Frank Viernau <frank_viernau@epam.com>
  • Loading branch information
fviernau committed Jul 1, 2024
1 parent 1331ef7 commit 62ba50f
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions plugins/package-managers/stack/src/main/kotlin/Stack.kt
Original file line number Diff line number Diff line change
Expand Up @@ -181,9 +181,6 @@ class Stack(
}
}

fun List<Dependency>.getProjectDependencies(): List<String> =
single { it.location?.type == PROJECT_PACKAGE_TYPE }.dependencies

val scopes = setOf(
Scope(EXTERNAL_SCOPE_NAME, externalDependencyList.getProjectDependencies().toPackageReferences()),
Scope(TEST_SCOPE_NAME, testDependencyList.getProjectDependencies().toPackageReferences()),
Expand Down Expand Up @@ -339,3 +336,6 @@ class Stack(
)
}
}

private fun List<Dependency>.getProjectDependencies(): List<String> =
single { it.location?.type == PROJECT_PACKAGE_TYPE }.dependencies

0 comments on commit 62ba50f

Please sign in to comment.