Skip to content

Commit 49fae38

Browse files
committed
rebase: update samples & address cubic-dev-ai
1 parent 0cd2614 commit 49fae38

4 files changed

Lines changed: 8 additions & 4 deletions

File tree

  • modules/openapi-generator/src/main/resources/kotlin-client/libraries/jvm-spring-webclient/infrastructure
  • samples/client
    • echo_api/kotlin-jvm-spring-3-webclient/src/main/kotlin/org/openapitools/client/infrastructure
    • petstore
      • kotlin-jvm-spring-2-webclient/src/main/kotlin/org/openapitools/client/infrastructure
      • kotlin-jvm-spring-3-webclient/src/main/kotlin/org/openapitools/client/infrastructure

modules/openapi-generator/src/main/resources/kotlin-client/libraries/jvm-spring-webclient/infrastructure/ApiClient.kt.mustache

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,8 +78,9 @@ import reactor.core.publisher.Mono
7878
return baseUrl.dropLast(1) + basePath
7979
} else if(!baseUrl.endsWith("/") && !basePath.startsWith("/")) {
8080
return "$baseUrl/$basePath"
81+
} else {
82+
return baseUrl + basePath;
8183
}
82-
return baseUrl + basePath
8384
}
8485

8586
{{^nonPublicApi}}{{#explicitApi}}public {{/explicitApi}}{{/nonPublicApi}}inline fun <reified T: Any> parseDateToQueryString(value : T): String {

samples/client/echo_api/kotlin-jvm-spring-3-webclient/src/main/kotlin/org/openapitools/client/infrastructure/ApiClient.kt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,8 +78,9 @@ fun createUrlWithBasePath(baseUrl: String, basePath: String = ApiClient.BASE_PAT
7878
return baseUrl.dropLast(1) + basePath
7979
} else if(!baseUrl.endsWith("/") && !basePath.startsWith("/")) {
8080
return "$baseUrl/$basePath"
81+
} else {
82+
return baseUrl + basePath;
8183
}
82-
return baseUrl + basePath
8384
}
8485

8586
inline fun <reified T: Any> parseDateToQueryString(value : T): String {

samples/client/petstore/kotlin-jvm-spring-2-webclient/src/main/kotlin/org/openapitools/client/infrastructure/ApiClient.kt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,8 +78,9 @@ fun createUrlWithBasePath(baseUrl: String, basePath: String = ApiClient.BASE_PAT
7878
return baseUrl.dropLast(1) + basePath
7979
} else if(!baseUrl.endsWith("/") && !basePath.startsWith("/")) {
8080
return "$baseUrl/$basePath"
81+
} else {
82+
return baseUrl + basePath;
8183
}
82-
return baseUrl + basePath
8384
}
8485

8586
inline fun <reified T: Any> parseDateToQueryString(value : T): String {

samples/client/petstore/kotlin-jvm-spring-3-webclient/src/main/kotlin/org/openapitools/client/infrastructure/ApiClient.kt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,8 +78,9 @@ fun createUrlWithBasePath(baseUrl: String, basePath: String = ApiClient.BASE_PAT
7878
return baseUrl.dropLast(1) + basePath
7979
} else if(!baseUrl.endsWith("/") && !basePath.startsWith("/")) {
8080
return "$baseUrl/$basePath"
81+
} else {
82+
return baseUrl + basePath;
8183
}
82-
return baseUrl + basePath
8384
}
8485

8586
inline fun <reified T: Any> parseDateToQueryString(value : T): String {

0 commit comments

Comments
 (0)