File tree Expand file tree Collapse file tree
apps/roam/src/components/settings/utils Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -110,14 +110,14 @@ const migrateSection = ({
110110 return true ;
111111} ;
112112
113- const migrateDiscourseNodes = ( ) : boolean => {
114- const nodePages = window . roamAlphaAPI . data . fast . q ( `
113+ const migrateDiscourseNodes = async ( ) : Promise < boolean > => {
114+ const nodePages = ( await window . roamAlphaAPI . data . backend . q ( `
115115 [:find ?uid ?title
116116 :where
117117 [?page :node/title ?title]
118118 [?page :block/uid ?uid]
119119 [(clojure.string/starts-with? ?title "${ DISCOURSE_NODE_PAGE_PREFIX } ")]]
120- ` ) as [ string , string ] [ ] ;
120+ ` ) ) as [ string , string ] [ ] ;
121121
122122 let allOk = true ;
123123
@@ -241,7 +241,7 @@ export const migrateGraphLevel = async (
241241 }
242242 }
243243
244- if ( ! migrateDiscourseNodes ( ) ) {
244+ if ( ! ( await migrateDiscourseNodes ( ) ) ) {
245245 failures ++ ;
246246 }
247247
You can’t perform that action at this time.
0 commit comments