diff --git a/stream-video-android-core/src/main/kotlin/io/getstream/video/android/core/internal/module/ConnectionModule.kt b/stream-video-android-core/src/main/kotlin/io/getstream/video/android/core/internal/module/ConnectionModule.kt index 2b5b85b0e5..3852d66441 100644 --- a/stream-video-android-core/src/main/kotlin/io/getstream/video/android/core/internal/module/ConnectionModule.kt +++ b/stream-video-android-core/src/main/kotlin/io/getstream/video/android/core/internal/module/ConnectionModule.kt @@ -41,6 +41,7 @@ import retrofit2.converter.moshi.MoshiConverterFactory import retrofit2.converter.scalars.ScalarsConverterFactory import retrofit2.converter.wire.WireConverterFactory import java.io.IOException +import java.text.Normalizer import java.util.concurrent.TimeUnit /** @@ -338,8 +339,14 @@ internal class HeadersInterceptor( } }.getOrNull() ?: "StandAloneInstall" - return "$appName / $versionName($versionCode); $installerName; ($manufacturer; " + - "$model; SDK $version; Android $versionRelease)" + return ("$appName / $versionName($versionCode); $installerName; ($manufacturer; " + + "$model; SDK $version; Android $versionRelease)") + .sanitize() } } + + private fun String.sanitize(): String { + return Normalizer.normalize(this, Normalizer.Form.NFD) + .replace("[^\\p{ASCII}]".toRegex(), "") + } }