share: fix detekt findings
- Commit
7e43074ec28381f3d1c94c0cefe98d7316e5adad- Author
- Vayun Mathur <[email protected]>
- When
- 2026-11-17 15:16 UTC (18 days ago)
- Parents
183ec35
Fixes every error-severity detekt finding in share (inventory clusters C3/C4): named constants for magic numbers, extracted functions/composables for long/complex methods, wrapped long lines, removed unused parameters, and narrowed/logged exception handling. No detekt config, baseline or suppression changes; behaviour preserved. Verified: ./check share and :share:testDevUnitTest green.
Diff
share/src/main/java/com/vayunmathur/share/platform/receive/ShareReceiveNotifier.kt
diff --git a/share/src/main/java/com/vayunmathur/share/platform/receive/ShareReceiveNotifier.kt b/share/src/main/java/com/vayunmathur/share/platform/receive/ShareReceiveNotifier.ktindex 3688274568..292833cd23 100644--- a/share/src/main/java/com/vayunmathur/share/platform/receive/ShareReceiveNotifier.kt+++ b/share/src/main/java/com/vayunmathur/share/platform/receive/ShareReceiveNotifier.kt@@ -334,7 +334,9 @@ class ShareReceiveNotifier( ): android.app.Notification { val builder = base(CHANNEL_TRANSFERS) .setContentTitle(conn.displayName)- .setContentText(appContext.resources.getQuantityString(R.plurals.share_received_count, received.size, received.size))+ .setContentText(+ appContext.resources.getQuantityString(R.plurals.share_received_count, received.size, received.size),+ ) .setAutoCancel(true) previewBitmap(received)?.let { preview -> // `bigLargeIcon(null)` so expanding drops the thumbnail instead of showing the same