mirror of
https://github.com/meshtastic/Meshtastic-Android.git
synced 2026-04-02 13:12:48 -04:00
fix: primaryChannel IndexOutOfBoundsException
This commit is contained in:
@@ -41,7 +41,7 @@ data class ChannelSet(
|
||||
*/
|
||||
val primaryChannel: Channel?
|
||||
get() = with(protobuf) {
|
||||
Channel(getSettings(0), loraConfig).takeIf { settingsCount > 0 }
|
||||
if (settingsCount > 0) Channel(getSettings(0), loraConfig) else null
|
||||
}
|
||||
|
||||
/// Return an URL that represents the current channel values
|
||||
|
||||
Reference in New Issue
Block a user