« get me outta code hell

hsmusic-wiki - HSMusic - static wiki software cataloguing collaborative creation
about summary refs log tree commit diff
path: root/src/data/things/group.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/data/things/group.js')
-rw-r--r--src/data/things/group.js27
1 files changed, 10 insertions, 17 deletions
diff --git a/src/data/things/group.js b/src/data/things/group.js
index 873c6d88..f53fa48e 100644
--- a/src/data/things/group.js
+++ b/src/data/things/group.js
@@ -5,7 +5,6 @@ import Thing, {
   directory,
   name,
   referenceList,
-  resolvedReferenceList,
   simpleString,
   urls,
   wikiData,
@@ -24,7 +23,11 @@ export class Group extends Thing {
 
     urls: urls(),
 
-    featuredAlbumsByRef: referenceList(Album),
+    featuredAlbums: referenceList({
+      class: Album,
+      find: find.album,
+      data: 'albumData',
+    }),
 
     // Update only
 
@@ -33,12 +36,6 @@ export class Group extends Thing {
 
     // Expose only
 
-    featuredAlbums: resolvedReferenceList({
-      list: 'featuredAlbumsByRef',
-      data: 'albumData',
-      find: find.album,
-    }),
-
     descriptionShort: {
       flags: {expose: true},
 
@@ -89,18 +86,14 @@ export class GroupCategory extends Thing {
     name: name('Unnamed Group Category'),
     color: color(),
 
-    groupsByRef: referenceList(Group),
+    groups: referenceList({
+      class: Group,
+      find: find.group,
+      data: 'groupData',
+    }),
 
     // Update only
 
     groupData: wikiData(Group),
-
-    // Expose only
-
-    groups: resolvedReferenceList({
-      list: 'groupsByRef',
-      data: 'groupData',
-      find: find.group,
-    }),
   });
 }