FIX treeview/util

This commit is contained in:
Norbert de Langen 2020-02-07 20:10:25 +01:00
parent 6820bb7cb0
commit bbe5d494c1
No known key found for this signature in database
GPG Key ID: 976651DA156C2825

View File

@ -167,8 +167,9 @@ export const getNext = ({
const mains = getMainsKeys(dataset);
const parents = getParents(id, dataset);
// .concat([{ children: mains }]);
// we add a face super-root, otherwise we won't be able to jump to the next root
const superRoot = { children: mains } as Item;
const parents = getParents(id, dataset).concat([superRoot]);
const next = parents.reduce(
(acc, item) => {