Skip to content

Commit

Permalink
Fixes #1517:
Browse files Browse the repository at this point in the history
When we build category tree, we ignore colors in subcategories
When we edit category, we pass parentid into content provider, so that is knows we handle a subcategory
  • Loading branch information
mtotschnig committed Jun 17, 2024
1 parent f12372b commit 40fe5b8
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -280,7 +280,7 @@ open class CategoryViewModel(
id = edit.category?.id?.takeIf { it != 0L },
label = label,
icon = icon,
parentId = edit.parent?.id,
parentId = edit.parent?.id ?: edit.category?.parentId,
type = typeFlags
)
dialogState = edit.copy(saving = true)
Expand Down Expand Up @@ -646,7 +646,7 @@ open class CategoryViewModel(
nextLabel,
nextPath,
ingest(
withColors,
false,
cursor,
nextId,
level + 1,
Expand Down

0 comments on commit 40fe5b8

Please sign in to comment.