android, desktop: show alert when server test fails (#6251)

This commit is contained in:
Evgeny
2025-09-08 11:07:13 +01:00
committed by GitHub
parent 99c919427f
commit b3bf9842e0
2 changed files with 14 additions and 0 deletions

View File

@@ -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
)
}
}
}
},

View File

@@ -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
)
}
}
}
},