« get me outta code hell

data steps: linkTemplate snapshot tests - hsmusic-wiki - HSMusic - static wiki software cataloguing collaborative creation
about summary refs log tree commit diff
path: root/src/content-function.js
diff options
context:
space:
mode:
author(quasar) nebula <qznebula@protonmail.com>2023-03-26 08:42:14 -0300
committer(quasar) nebula <qznebula@protonmail.com>2023-03-26 08:42:14 -0300
commit4e6f3c16818d9beb200c337d48c8ae2470a322ee (patch)
treeb05bc1f5df177572bdf61eb32d0c34823d010ce1 /src/content-function.js
parent5dfdb661c4672bcf432c9bd283a2ffec5a3c1cb3 (diff)
data steps: linkTemplate snapshot tests
Diffstat (limited to 'src/content-function.js')
-rw-r--r--src/content-function.js6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/content-function.js b/src/content-function.js
index 0a21780..377eecc 100644
--- a/src/content-function.js
+++ b/src/content-function.js
@@ -279,7 +279,9 @@ export function flattenRelationsTree({
     }
   }
 
-  recursive(relationsTree);
+  if (relationsTree) {
+    recursive(relationsTree);
+  }
 
   return {
     root,
@@ -335,7 +337,7 @@ export function quickEvaluate({
   extraDependencies: allExtraDependencies,
 
   name,
-  args,
+  args = [],
 }) {
   const treeInfo = getRelationsTree(allContentDependencies, name, ...args);
   const flatTreeInfo = flattenRelationsTree(treeInfo);