diff --git a/CHANGELOG.md b/CHANGELOG.md index 925a1618e4f..457bd88e9d5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,10 @@ ## 0.9.10 +* Ktor: + * Client: + * New function `UnifiedRequester#createStandardWebsocketFlow` without `checkReconnection` arg + ## 0.9.9 * `Versions`: diff --git a/ktor/client/src/commonMain/kotlin/dev/inmo/micro_utils/ktor/client/StandardHttpClientGetPost.kt b/ktor/client/src/commonMain/kotlin/dev/inmo/micro_utils/ktor/client/StandardHttpClientGetPost.kt index 0cc8af023aa..dc3d88a235f 100644 --- a/ktor/client/src/commonMain/kotlin/dev/inmo/micro_utils/ktor/client/StandardHttpClientGetPost.kt +++ b/ktor/client/src/commonMain/kotlin/dev/inmo/micro_utils/ktor/client/StandardHttpClientGetPost.kt @@ -85,9 +85,14 @@ class UnifiedRequester( fun createStandardWebsocketFlow( url: String, - checkReconnection: (Throwable?) -> Boolean = { true }, + checkReconnection: (Throwable?) -> Boolean, deserializer: DeserializationStrategy ) = client.createStandardWebsocketFlow(url, checkReconnection, deserializer, serialFormat) + + fun createStandardWebsocketFlow( + url: String, + deserializer: DeserializationStrategy + ) = createStandardWebsocketFlow(url, { true }, deserializer) } val defaultRequester = UnifiedRequester()