From cd89634fd648df2d009a2f52dd108fc90edcff66 Mon Sep 17 00:00:00 2001 From: Zef Hemel Date: Tue, 17 May 2022 08:32:33 +0200 Subject: [PATCH] Changes --- packages/common/types.ts | 2 +- packages/plugs/search/search.ts | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/packages/common/types.ts b/packages/common/types.ts index aaaa1ddb..dce7317e 100644 --- a/packages/common/types.ts +++ b/packages/common/types.ts @@ -2,7 +2,7 @@ export type PageMeta = { name: string; lastModified: number; lastOpened?: number; - created?: boolean; + perm: "ro" | "rw"; }; // Used by FilterBox diff --git a/packages/plugs/search/search.ts b/packages/plugs/search/search.ts index 9d638220..102740a0 100644 --- a/packages/plugs/search/search.ts +++ b/packages/plugs/search/search.ts @@ -20,7 +20,9 @@ export async function queryProvider({ } let results = await fullTextSearch(phraseFilter.value, 100); - let allPageMap: Map = new Map(results.map((r) => [r.name, r])); + let allPageMap: Map = new Map( + results.map((r: any) => [r.name, r]) + ); for (let { page, value } of await scanPrefixGlobal("meta:")) { let p = allPageMap.get(page); if (p) {