From 67b3749718cbec0fde85c402c0fba427ad9addbc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ivan=20=E2=80=9CCLOVIS=E2=80=9D=20Canet?= Date: Wed, 3 Jun 2026 19:34:06 +0200 Subject: [PATCH] style(api): Simplify & clean up --- api/src/commonMain/kotlin/Resource.kt | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/api/src/commonMain/kotlin/Resource.kt b/api/src/commonMain/kotlin/Resource.kt index 932dac2..c4f2474 100644 --- a/api/src/commonMain/kotlin/Resource.kt +++ b/api/src/commonMain/kotlin/Resource.kt @@ -330,7 +330,7 @@ val Resource.hierarchy: Sequence * @see Resource.slug The segment of this specific resource. */ val Resource.fullSlug: String - get() = hierarchy.map { it.slug }.joinToString("/") + get() = hierarchy.joinToString("/") { it.slug } /** * Returns all endpoints that are declared on this resource or any of its children. @@ -340,7 +340,3 @@ val Resource.fullSlug: String */ val Resource.endpoints: Sequence get() = directEndpoints + children.flatMap { it.endpoints } - -internal fun Resource.extendPath(extension: String? = null) = - if (extension != null) "$fullSlug/$extension" - else fullSlug -- 2.51.2