diff options
author | (quasar) nebula <qznebula@protonmail.com> | 2024-03-07 12:01:45 -0400 |
---|---|---|
committer | (quasar) nebula <qznebula@protonmail.com> | 2024-06-18 22:56:03 -0300 |
commit | 588868e9b0f459a25aa0ade2c4a1a9e2701f729b (patch) | |
tree | a04bcaa25cc11ed7fb8beeb2e9a37b4c7977728a /src/data/things | |
parent | 385721c1f2c37581dfa8473259ca4c98f7d9921d (diff) |
data: withCoverArtDate
Diffstat (limited to 'src/data/things')
-rw-r--r-- | src/data/things/album.js | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/src/data/things/album.js b/src/data/things/album.js index d2942fc7..6b37bc96 100644 --- a/src/data/things/album.js +++ b/src/data/things/album.js @@ -18,8 +18,13 @@ import {parseAdditionalFiles, parseContributors, parseDate, parseDimensions} import {exitWithoutDependency, exposeDependency, exposeUpdateValueOrContinue} from '#composite/control-flow'; import {withPropertyFromObject} from '#composite/data'; -import {exitWithoutContribs, withDirectory, withResolvedReference} - from '#composite/wiki-data'; + +import { + exitWithoutContribs, + withDirectory, + withResolvedReference, + withCoverArtDate, +} from '#composite/wiki-data'; import { additionalFiles, @@ -73,13 +78,12 @@ export class Album extends Thing { dateAddedToWiki: simpleDate(), coverArtDate: [ - exitWithoutContribs({contribs: 'coverArtistContribs'}), - - exposeUpdateValueOrContinue({ - validate: input.value(isDate), + // TODO: Why does this fall back, but Track.coverArtDate doesn't? + withCoverArtDate({ + fallback: input.value(true), }), - exposeDependency({dependency: 'date'}), + exposeDependency({dependency: '#coverArtDate'}), ], coverArtFileExtension: [ |