Skip to content

Commit

Permalink
fix: fixed cannot read map of null errors
Browse files Browse the repository at this point in the history
  • Loading branch information
ahonn committed Oct 14, 2022
1 parent 755eec5 commit 8866d0b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/state/tasks.ts
Expand Up @@ -8,7 +8,7 @@ async function getTaskEntitiesByQuery(query: string) {
query,
);
const tasks = await Promise.all(
collections.map(async ([item]) => {
(collections ?? []).map(async ([item]) => {
const uuid = getBlockUUID(item);
const block = await window.logseq.Editor.getBlock(uuid, {
includeChildren: true,
Expand Down

0 comments on commit 8866d0b

Please sign in to comment.