Skip to content

Commit

Permalink
lib.makeTags - Small cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
Inrixia committed Oct 7, 2024
1 parent fab593c commit 3525aca
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions plugins/_lib/makeTags.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,12 @@ export const fullTitle = (tidal?: { title?: string; version?: string }, musicBra
const tidalTitle = tidal?.title;

let title = brainzTitle ?? tidalTitle;

// // If the musicBrainz title is missing "feat .", use the tidal title.
// const mbMissingFeat = tidalTitle?.includes("feat. ") && !brainzTitle?.includes("feat. ");
if (title === undefined) return undefined;

// If the musicBrainz title is in another language and the tidal one isnt, use the tidal title.
const mbInAnotherLanguage = !hasEnglish(brainzTitle) && hasEnglish(tidalTitle);

if (mbInAnotherLanguage) title = tidalTitle;
if (title === undefined) return undefined;
if (mbInAnotherLanguage && tidalTitle !== undefined) title = tidalTitle;

// Dont use musicBrainz disambiguation as its not the same as the tidal version!
const version = tidal?.version;
Expand Down

0 comments on commit 3525aca

Please sign in to comment.