diff --git a/src/_data/albums.js b/src/_data/albums.js index ddf3eaff..9e7b833d 100644 --- a/src/_data/albums.js +++ b/src/_data/albums.js @@ -23,7 +23,9 @@ module.exports = async function () { : `https://cdn.coryd.dev/albums/${album['name'].name .replace(/\s+/g, '-') .toLowerCase()}.jpg`, - url: `https://musicbrainz.org/album/${album['mbid']}`, + url: album['mbid'] + ? `https://musicbrainz.org/album/${album['mbid']}` + : `https://rateyourmusic.com/search?searchtype=l&searchterm=${encodeURI(album['name'])}`, } }) } diff --git a/src/_data/artists.js b/src/_data/artists.js index 4ea27766..98f5caee 100644 --- a/src/_data/artists.js +++ b/src/_data/artists.js @@ -16,7 +16,9 @@ module.exports = async function () { image: `https://cdn.coryd.dev/artists/${artist['name'].replace(/\s+/g, '-').toLowerCase()}.jpg` || 'https://cdn.coryd.dev/artists/missing-artist.jpg', - url: `https://musicbrainz.org/artist/${artist['mbid']}`, + url: artist['mbid'] + ? `https://musicbrainz.org/artist/${artist['mbid']}` + : `https://rateyourmusic.com/search?searchterm=${encodeURI(artist['name'])}`, } }) }