mirror of
https://github.com/simplex-chat/simplex-chat.git
synced 2026-03-30 01:19:54 +00:00
android, desktop: show alert when server test fails (#6251)
This commit is contained in:
@@ -43,6 +43,13 @@ fun ModalData.NewServerView(
|
||||
if (isActive) {
|
||||
newServer.value = res.first
|
||||
testing.value = false
|
||||
val failure = res.second
|
||||
if (failure != null) {
|
||||
AlertManager.shared.showAlertMsg(
|
||||
title = generalGetString(MR.strings.smp_servers_test_failed),
|
||||
text = failure.localizedDescription
|
||||
)
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
@@ -93,6 +93,13 @@ fun ProtocolServerView(
|
||||
if (isActive) {
|
||||
draftServer.value = res.first
|
||||
testing.value = false
|
||||
val failure = res.second
|
||||
if (failure != null) {
|
||||
AlertManager.shared.showAlertMsg(
|
||||
title = generalGetString(MR.strings.smp_servers_test_failed),
|
||||
text = failure.localizedDescription
|
||||
)
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user