From ffffbc81426bb6ccd07ee6084a9c40fb126222ff Mon Sep 17 00:00:00 2001 From: "(quasar) nebula" Date: Tue, 25 Nov 2025 14:55:54 -0400 Subject: data: Track: chop withDate --- src/data/composite/things/track/withDate.js | 42 ----------------------------- 1 file changed, 42 deletions(-) delete mode 100644 src/data/composite/things/track/withDate.js (limited to 'src/data/composite/things/track/withDate.js') diff --git a/src/data/composite/things/track/withDate.js b/src/data/composite/things/track/withDate.js deleted file mode 100644 index 1851c0d2..00000000 --- a/src/data/composite/things/track/withDate.js +++ /dev/null @@ -1,42 +0,0 @@ -// Gets the track's own date. This is either its dateFirstReleased property -// or, if unset, the album's date. - -import {input, templateCompositeFrom} from '#composite'; - -import withPropertyFromAlbum from './withPropertyFromAlbum.js'; - -export default templateCompositeFrom({ - annotation: `withDate`, - - outputs: ['#date'], - - steps: () => [ - { - dependencies: ['disableDate'], - compute: (continuation, {disableDate}) => - (disableDate - ? continuation.raiseOutput({'#date': null}) - : continuation()), - }, - - { - dependencies: ['dateFirstReleased'], - compute: (continuation, {dateFirstReleased}) => - (dateFirstReleased - ? continuation.raiseOutput({'#date': dateFirstReleased}) - : continuation()), - }, - - withPropertyFromAlbum({ - property: input.value('date'), - }), - - { - dependencies: ['#album.date'], - compute: (continuation, {['#album.date']: albumDate}) => - (albumDate - ? continuation.raiseOutput({'#date': albumDate}) - : continuation.raiseOutput({'#date': null})), - }, - ], -}) -- cgit 1.3.0-6-gf8a5