diff options
author | (quasar) nebula <qznebula@protonmail.com> | 2022-01-01 22:46:14 -0400 |
---|---|---|
committer | (quasar) nebula <qznebula@protonmail.com> | 2022-01-01 22:46:14 -0400 |
commit | 1b4a8e79e94d67444675b43c1a40c161b9d6b3db (patch) | |
tree | f730436de16108d6f10aa40849739bbf791852e9 | |
parent | febc48a2d50e5440ee598f594676e1e8aeafbff5 (diff) | |
parent | 40d0c09ea64a6e0d3bd93e902a14218a96e95933 (diff) |
Merge branch 'staging' of notabug.org:hsmusic/hsmusic-wiki into staging
-rwxr-xr-x | src/upd8.js | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/upd8.js b/src/upd8.js index 26572aa7..29063f87 100755 --- a/src/upd8.js +++ b/src/upd8.js @@ -782,6 +782,11 @@ async function processAlbumDataFile(file) { const album = {}; album.name = getBasicField(albumSection, 'Album'); + + if (!album.name) { + return {error: `The file "${path.relative(dataPath, file)}" is missing the "Album" field - maybe this is a misplaced file instead of album data?`}; + } + album.artists = getContributionField(albumSection, 'Artists') || getContributionField(albumSection, 'Artist'); album.wallpaperArtists = getContributionField(albumSection, 'Wallpaper Art'); album.wallpaperStyle = getMultilineField(albumSection, 'Wallpaper Style'); |