fix: convert SNR values to `Float` for decimal precision

pull/1402/head
andrekir 2024-11-11 16:41:06 -03:00
rodzic 1ae65ef267
commit 1d992d5caf
1 zmienionych plików z 1 dodań i 1 usunięć

Wyświetl plik

@ -33,7 +33,7 @@ private fun formatTraceroutePath(nodesList: List<String>, snrList: List<Int>): S
// use unknown SNR for entire route if snrList has invalid size
List(nodesList.size - 1) { -128 }
}.map { snr ->
val str = if (snr == -128) "?" else "${snr / 4}"
val str = if (snr == -128) "?" else "${snr / 4f}"
"$str dB"
}