Skip to content

A fully open source & end-to-end encrypted note taking alternative to Evernote.

fix: do not increase group count while adding group

thecodrra6e724e2118b
diff --git a/apps/web/src/components/dialogs/toolbar-config-dialog.tsx b/apps/web/src/components/dialogs/toolbar-config-dialog.tsx
index 3ef25edc7..68207f5dd 100644
--- a/apps/web/src/components/dialogs/toolbar-config-dialog.tsx
+++ b/apps/web/src/components/dialogs/toolbar-config-dialog.tsx
@@ -654,7 +654,7 @@ function addGroup(items: TreeNode[]) {
const newArray = items.slice();
const groups = items.filter((t) => isGroup(t) && !isSubgroup(t));
- const newGroup = createGroup({ title: `Group ${groups.length + 1}` });
+ const newGroup = createGroup({ title: `Group ${groups.length}` });
newArray.splice(insertIndex, 0, newGroup);
return newArray;
}