« get me outta code hell

data: withReverseReferenceList: use withPropertyFromList - hsmusic-wiki - HSMusic - static wiki software cataloguing collaborative creation
about summary refs log tree commit diff
diff options
context:
space:
mode:
author(quasar) nebula <qznebula@protonmail.com>2025-01-11 13:11:16 -0400
committer(quasar) nebula <qznebula@protonmail.com>2025-01-11 13:11:16 -0400
commitf43e65bc650ba9847a5971ed6eaac18283e5cf34 (patch)
tree33285e2e921b0af83914dccb3bdb01feb862b429
parent9d99dafca9dc4e16b867b707746314040a8d9ba5 (diff)
data: withReverseReferenceList: use withPropertyFromList
-rw-r--r--src/data/composite/wiki-data/withReverseReferenceList.js18
1 files changed, 4 insertions, 14 deletions
diff --git a/src/data/composite/wiki-data/withReverseReferenceList.js b/src/data/composite/wiki-data/withReverseReferenceList.js
index 70d9a58d..41d2ff20 100644
--- a/src/data/composite/wiki-data/withReverseReferenceList.js
+++ b/src/data/composite/wiki-data/withReverseReferenceList.js
@@ -5,7 +5,7 @@ import withReverseList_template from './helpers/withReverseList-template.js';
 
 import {input} from '#composite';
 
-import {withMappedList} from '#composite/data';
+import {withPropertyFromList} from '#composite/data';
 
 export default withReverseList_template({
   annotation: `withReverseReferenceList`,
@@ -14,21 +14,11 @@ export default withReverseList_template({
   outputName: '#reverseReferenceList',
 
   customCompositionSteps: () => [
-    {
-      dependencies: [input('list')],
-      compute: (continuation, {
-        [input('list')]: list,
-      }) => continuation({
-        ['#referenceMap']:
-          thing => thing[list],
-      }),
-    },
-
-    withMappedList({
+    withPropertyFromList({
       list: input('data'),
-      map: '#referenceMap',
+      property: input('list'),
     }).outputs({
-      '#mappedList': '#referencedThings',
+      '#values': '#referencedThings',
     }),
 
     {