From 982bda6347c6033334c2f70f5fa10ac5b32314f2 Mon Sep 17 00:00:00 2001 From: alperozturk Date: Tue, 5 Dec 2023 11:34:37 +0100 Subject: [PATCH] Fix code analytics Signed-off-by: alperozturk --- .../java/com/nextcloud/client/widget/DashboardWidgetService.kt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/src/main/java/com/nextcloud/client/widget/DashboardWidgetService.kt b/app/src/main/java/com/nextcloud/client/widget/DashboardWidgetService.kt index 78e53fd54d..19b8a983fa 100644 --- a/app/src/main/java/com/nextcloud/client/widget/DashboardWidgetService.kt +++ b/app/src/main/java/com/nextcloud/client/widget/DashboardWidgetService.kt @@ -163,7 +163,7 @@ class StackRemoteViewsFactory( // we will switch soon to coil and then streamline all of this // Kotlin cannot catch multiple exception types at same time - @Suppress("NestedBlockDepth", "TooGenericExceptionCaught") + @Suppress("NestedBlockDepth") private fun createItemView(position: Int): RemoteViews { return RemoteViews(context.packageName, R.layout.widget_item).apply { if (widgetItems.isEmpty()) { @@ -185,6 +185,7 @@ class StackRemoteViewsFactory( } } + @Suppress( "TooGenericExceptionCaught") private fun loadIcon(widgetItem: DashboardWidgetItem, remoteViews: RemoteViews) { val isIconSVG = Uri.parse(widgetItem.iconUrl).encodedPath!!.endsWith(".svg") val source: FutureTarget = if (isIconSVG) {