« get me outta code hell

hsmusic-wiki - HSMusic - static wiki software cataloguing collaborative creation
about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--src/content-function.js13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/content-function.js b/src/content-function.js
index 377eecc9..30e0ccc3 100644
--- a/src/content-function.js
+++ b/src/content-function.js
@@ -338,7 +338,20 @@ export function quickEvaluate({
 
   name,
   args = [],
+  multiple = null,
 }) {
+  if (multiple !== null) {
+    return multiple.map(opts =>
+      quickEvaluate({
+        contentDependencies: allContentDependencies,
+        extraDependencies: allExtraDependencies,
+
+        ...opts,
+        name: opts.name ?? name,
+        args: opts.args ?? args,
+      }));
+  }
+
   const treeInfo = getRelationsTree(allContentDependencies, name, ...args);
   const flatTreeInfo = flattenRelationsTree(treeInfo);
   const {root, relationIdentifier, flatRelationSlots} = flatTreeInfo;