From a584c8da1726745ddd5e2ef850d69d93c27f2bf2 Mon Sep 17 00:00:00 2001 From: tibbi <tibor@kaputa.sk> Date: Thu, 27 Dec 2018 15:53:56 +0100 Subject: [PATCH] properly remove the checklists placeholder at adding new items --- .../simplemobiletools/notes/pro/fragments/ChecklistFragment.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/pro/fragments/ChecklistFragment.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/fragments/ChecklistFragment.kt index 7ba06b53..234c7fd3 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/pro/fragments/ChecklistFragment.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/fragments/ChecklistFragment.kt @@ -87,7 +87,7 @@ class ChecklistFragment : NoteFragment(), ChecklistItemsListener { currentMaxId++ } saveNote() - if (items.size == 1) { + if (items.size == it.size) { setupAdapter() } else { (view.checklist_list.adapter as? ChecklistAdapter)?.notifyDataSetChanged()