fix: verbessere Fallback-Logik für Gerätenamen in JmDnsDiscoveryService
Feature Build — Windows MSI / 📦 Windows .msi Packaging (push) Has been cancelled
Feature Build — Windows MSI / 📦 Windows .msi Packaging (push) Has been cancelled
Signed-off-by: StefanMoCoAt <stefan.mo.co@gmail.com>
This commit is contained in:
+4
-4
@@ -88,11 +88,11 @@ class JmDnsDiscoveryService : NetworkDiscoveryService {
|
||||
}
|
||||
}
|
||||
|
||||
val name = deviceName ?: try {
|
||||
java.net.InetAddress.getLocalHost().hostName
|
||||
} catch (e: Exception) {
|
||||
val name = deviceName ?: (try {
|
||||
InetAddress.getLocalHost().hostName
|
||||
} catch (_: Exception) {
|
||||
"Meldestelle-Device"
|
||||
} + "-${System.getProperty("user.name", "unknown")}"
|
||||
} + "-${System.getProperty("user.name", "unknown")}")
|
||||
|
||||
jmdnsInstances.forEach { jmdns ->
|
||||
val serviceInfo = ServiceInfo.create(
|
||||
|
||||
Reference in New Issue
Block a user