summaryrefslogtreecommitdiffhomepage
path: root/android/lib/daemon-grpc/src
diff options
context:
space:
mode:
authorJonatan Rhodin <jonatan.rhodin@mullvad.net>2025-04-07 15:20:30 +0200
committerJonatan Rhodin <jonatan.rhodin@mullvad.net>2025-04-09 09:46:21 +0200
commit0db6e80bbc591eeefb2408fa2e335b2804135eb2 (patch)
tree3b465d233d94a4739f9a0850607fc0424c9cb8af /android/lib/daemon-grpc/src
parent9a6938a4a32ecc162cc5afcf15fa636de2f9b9fe (diff)
downloadmullvadvpn-0db6e80bbc591eeefb2408fa2e335b2804135eb2.tar.xz
mullvadvpn-0db6e80bbc591eeefb2408fa2e335b2804135eb2.zip
Improve error message when an unavailable ip version is selected
Diffstat (limited to 'android/lib/daemon-grpc/src')
-rw-r--r--android/lib/daemon-grpc/src/main/kotlin/net/mullvad/mullvadvpn/lib/daemon/grpc/mapper/ToDomain.kt6
1 files changed, 5 insertions, 1 deletions
diff --git a/android/lib/daemon-grpc/src/main/kotlin/net/mullvad/mullvadvpn/lib/daemon/grpc/mapper/ToDomain.kt b/android/lib/daemon-grpc/src/main/kotlin/net/mullvad/mullvadvpn/lib/daemon/grpc/mapper/ToDomain.kt
index 40ee4d6bcf..10c417cf1c 100644
--- a/android/lib/daemon-grpc/src/main/kotlin/net/mullvad/mullvadvpn/lib/daemon/grpc/mapper/ToDomain.kt
+++ b/android/lib/daemon-grpc/src/main/kotlin/net/mullvad/mullvadvpn/lib/daemon/grpc/mapper/ToDomain.kt
@@ -302,7 +302,11 @@ internal fun ManagementInterface.ErrorState.GenerationError.toDomain(): Paramete
ManagementInterface.ErrorState.GenerationError.NO_WIREGUARD_KEY ->
ParameterGenerationError.NoWireguardKey
ManagementInterface.ErrorState.GenerationError.CUSTOM_TUNNEL_HOST_RESOLUTION_ERROR ->
- ParameterGenerationError.CustomTunnelHostResultionError
+ ParameterGenerationError.CustomTunnelHostResolutionError
+ ManagementInterface.ErrorState.GenerationError.NETWORK_IPV4_UNAVAILABLE ->
+ ParameterGenerationError.Ipv4_Unavailable
+ ManagementInterface.ErrorState.GenerationError.NETWORK_IPV6_UNAVAILABLE ->
+ ParameterGenerationError.Ipv6_Unavailable
ManagementInterface.ErrorState.GenerationError.UNRECOGNIZED ->
throw IllegalArgumentException("Unrecognized parameter generation error")
}