From a5f1f1226b9c0dd9aec0729faa75b5797041a5d6 Mon Sep 17 00:00:00 2001 From: Agnieszka C <85929121+Aga-C@users.noreply.github.com> Date: Thu, 17 Mar 2022 11:42:03 +0100 Subject: [PATCH] Fixed missing content of checklist widget --- .../com/simplemobiletools/notes/pro/adapters/WidgetAdapter.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/pro/adapters/WidgetAdapter.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/adapters/WidgetAdapter.kt index 419d1529..b270d307 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/pro/adapters/WidgetAdapter.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/adapters/WidgetAdapter.kt @@ -125,7 +125,7 @@ class WidgetAdapter(val context: Context, val intent: Intent) : RemoteViewsServi note = context.notesDB.getNoteWithId(noteId) if (note?.type == NoteType.TYPE_CHECKLIST.value) { val checklistItemType = object : TypeToken>() {}.type - checklistItems = Gson().fromJson>(note!!.value, checklistItemType) ?: ArrayList(1) + checklistItems = Gson().fromJson>(note!!.getNoteStoredValue(context), checklistItemType) ?: ArrayList(1) // checklist title can be null only because of the glitch in upgrade to 6.6.0, remove this check in the future checklistItems = checklistItems.filter { it.title != null }.toMutableList() as ArrayList