From 9ff811b9e0b3301256f8eb7000e62ea8bb1bd510 Mon Sep 17 00:00:00 2001 From: James Rich <2199651+jamesarich@users.noreply.github.com> Date: Sat, 14 Dec 2024 14:54:12 -0600 Subject: [PATCH] fix: make detekt happy --- app/src/main/java/com/geeksville/mesh/service/MeshService.kt | 2 -- app/src/main/java/com/geeksville/mesh/ui/message/Message.kt | 1 + .../com/geeksville/mesh/ui/message/components/MessageItem.kt | 3 ++- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/app/src/main/java/com/geeksville/mesh/service/MeshService.kt b/app/src/main/java/com/geeksville/mesh/service/MeshService.kt index 13b5d8ecb..a29234340 100644 --- a/app/src/main/java/com/geeksville/mesh/service/MeshService.kt +++ b/app/src/main/java/com/geeksville/mesh/service/MeshService.kt @@ -684,8 +684,6 @@ class MeshService : Service(), Logging { packetRepository.get().insertReply(reply) } - - private fun rememberDataPacket(dataPacket: DataPacket, updateNotification: Boolean = true) { if (dataPacket.dataType !in rememberDataType) return val fromLocal = dataPacket.from == DataPacket.ID_LOCAL diff --git a/app/src/main/java/com/geeksville/mesh/ui/message/Message.kt b/app/src/main/java/com/geeksville/mesh/ui/message/Message.kt index 4d796d5d3..bdef97d7e 100644 --- a/app/src/main/java/com/geeksville/mesh/ui/message/Message.kt +++ b/app/src/main/java/com/geeksville/mesh/ui/message/Message.kt @@ -460,6 +460,7 @@ private fun QuickChatRow( } } +@Suppress("LongMethod") @Composable private fun TextInput( enabled: Boolean, diff --git a/app/src/main/java/com/geeksville/mesh/ui/message/components/MessageItem.kt b/app/src/main/java/com/geeksville/mesh/ui/message/components/MessageItem.kt index 017757bf9..451738b54 100644 --- a/app/src/main/java/com/geeksville/mesh/ui/message/components/MessageItem.kt +++ b/app/src/main/java/com/geeksville/mesh/ui/message/components/MessageItem.kt @@ -69,7 +69,7 @@ import com.geeksville.mesh.ui.preview.NodeEntityPreviewParameterProvider import com.geeksville.mesh.ui.theme.AppTheme import com.geeksville.mesh.util.getShortDateTime -@Suppress("LongMethod") +@Suppress("LongMethod", "CyclomaticComplexMethod") @OptIn(ExperimentalMaterialApi::class, ExperimentalFoundationApi::class) @Composable internal fun MessageItem( @@ -264,6 +264,7 @@ private fun ReplyRow( } } +@Suppress("MagicNumber") @PreviewLightDark @Composable private fun MessageItemPreview() {