Skip to content

Commit

Permalink
Replace author name in track title in VEVO tracks
Browse files Browse the repository at this point in the history
  • Loading branch information
PapiOphidian committed Nov 20, 2023
1 parent 47d49d7 commit 20d730e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/runtime-website/src/music/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ const common = {
const trackNameMatch = trackNameRegex.exec(track.title)

if (authorNameMatch) {
title = track.title?.replace(replaceExtraneousRegex, "")?.trim()
title = track.title?.replace(new RegExp(`${authorNameMatch[1]} - ?`), "")?.replace(replaceExtraneousRegex, "")?.trim()
artist = authorNameMatch[1]?.trim()
confidence = 2
} else if (trackNameMatch) {
Expand Down

0 comments on commit 20d730e

Please sign in to comment.