diff --git a/apps/multiplatform/common/src/commonMain/kotlin/chat/simplex/common/model/SimpleXAPI.kt b/apps/multiplatform/common/src/commonMain/kotlin/chat/simplex/common/model/SimpleXAPI.kt
index 7648770afa..0b153ae7cf 100644
--- a/apps/multiplatform/common/src/commonMain/kotlin/chat/simplex/common/model/SimpleXAPI.kt
+++ b/apps/multiplatform/common/src/commonMain/kotlin/chat/simplex/common/model/SimpleXAPI.kt
@@ -1837,17 +1837,17 @@ object ChatController {
r is CR.ChatCmdError && r.chatError is ChatError.ChatErrorAgent
&& r.chatError.agentError is AgentErrorType.SMP
&& r.chatError.agentError.smpErr is SMPErrorType.PROXY ->
- proxyErrorAlert(r.chatError.agentError.smpErr.proxyErr)
+ proxyErrorAlert(r.chatError.agentError.smpErr.proxyErr, r.chatError.agentError.serverAddress)
r is CR.ChatCmdError && r.chatError is ChatError.ChatErrorAgent
&& r.chatError.agentError is AgentErrorType.PROXY
&& r.chatError.agentError.proxyErr is ProxyClientError.ProxyProtocolError
&& r.chatError.agentError.proxyErr.protocolErr is SMPErrorType.PROXY ->
- proxyErrorAlert(r.chatError.agentError.proxyErr.protocolErr.proxyErr)
+ proxyErrorAlert(r.chatError.agentError.proxyErr.protocolErr.proxyErr, r.chatError.agentError.proxyServer)
else -> false
}
}
- private fun proxyErrorAlert(pe: ProxyError): Boolean {
+ private fun proxyErrorAlert(pe: ProxyError, srvAddr: String): Boolean {
return when {
pe is ProxyError.BROKER
&& pe.brokerErr is BrokerErrorType.TIMEOUT -> {
@@ -1876,7 +1876,7 @@ object ChatController {
&& pe.brokerErr is BrokerErrorType.HOST -> {
AlertManager.shared.showAlertMsg(
generalGetString(MR.strings.private_routing_error),
- generalGetString(MR.strings.srv_error_host)
+ String.format(generalGetString(MR.strings.network_error_broker_host_desc), serverHostname(srvAddr))
)
true
}
@@ -1885,7 +1885,7 @@ object ChatController {
&& pe.brokerErr.transportErr is SMPTransportError.Version -> {
AlertManager.shared.showAlertMsg(
generalGetString(MR.strings.private_routing_error),
- generalGetString(MR.strings.srv_error_version)
+ String.format(generalGetString(MR.strings.proxy_error_broker_version_desc), serverHostname(srvAddr))
)
true
}
@@ -5569,7 +5569,7 @@ sealed class AgentErrorType {
}
@Serializable @SerialName("CMD") class CMD(val cmdErr: CommandErrorType): AgentErrorType()
@Serializable @SerialName("CONN") class CONN(val connErr: ConnectionErrorType): AgentErrorType()
- @Serializable @SerialName("SMP") class SMP(val smpErr: SMPErrorType): AgentErrorType()
+ @Serializable @SerialName("SMP") class SMP(val serverAddress: String, val smpErr: SMPErrorType): AgentErrorType()
// @Serializable @SerialName("NTF") class NTF(val ntfErr: SMPErrorType): AgentErrorType()
@Serializable @SerialName("XFTP") class XFTP(val xftpErr: XFTPErrorType): AgentErrorType()
@Serializable @SerialName("PROXY") class PROXY(val proxyServer: String, val relayServer: String, val proxyErr: ProxyClientError): AgentErrorType()
diff --git a/apps/multiplatform/common/src/commonMain/resources/MR/base/strings.xml b/apps/multiplatform/common/src/commonMain/resources/MR/base/strings.xml
index 7fbb4395d6..24bc6194cc 100644
--- a/apps/multiplatform/common/src/commonMain/resources/MR/base/strings.xml
+++ b/apps/multiplatform/common/src/commonMain/resources/MR/base/strings.xml
@@ -116,6 +116,7 @@
Server version is incompatible with your app: %1$s.
Private routing error
Please try later.
+ Server version is incompatible with network settings: %1$s.
Error sending message
Error creating message
Error loading details