Skip to content

Commit

Permalink
Update modules/ROOT/examples/live-demos/advtemplate-readonly-template…
Browse files Browse the repository at this point in the history
…/index.js

Co-authored-by: tiny-ben-tran <[email protected]>
  • Loading branch information
kemister85 and tiny-ben-tran authored Oct 8, 2024
1 parent a203cf9 commit 9f7c158
Showing 1 changed file with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -201,15 +201,14 @@ const create = (data = []) => {
}

const load = (items, id) => {
for (const item of items) {
items.forEach((item) => {
if (item.items) {
const category = createCategory(item.title, item.locked);
load(item.items, category.id );
} else {
createTemplate(item.title, item.content, id);
}
}
};
});

load(data);

Expand Down

0 comments on commit 9f7c158

Please sign in to comment.