diff --git a/src/filter.js b/src/filter.js index e89d3c7..e1c0075 100644 --- a/src/filter.js +++ b/src/filter.js @@ -375,8 +375,6 @@ class MetadataFilter { { source: /\sclip/i, target: '' }, // Full Album { source: /full\s*album/i, target: '' }, - // live - { source: /\s+live.*?$/i, target: '' }, // (live) { source: /\(live.*?\)$/i, target: '' }, // | something diff --git a/test/filter.js b/test/filter.js index 01eb2f4..f4118e9 100644 --- a/test/filter.js +++ b/test/filter.js @@ -264,14 +264,6 @@ const YOUTUBE_FILTER_RULES_TEST_DATA = [{ description: 'should remove "(Stream)" string', source: 'Track Title (Stream)', expected: 'Track Title' -}, { - description: 'should remove live suffix', - source: 'Track Title Live', - expected: 'Track Title' -}, { - description: 'should not remove "live" from string', - source: 'Fully Alive', - expected: 'Fully Alive' }, { description: 'should remove (live) suffix', source: 'Track Title (Live)', @@ -328,6 +320,18 @@ const YOUTUBE_FILTER_RULES_TEST_DATA = [{ description: 'should remove "(whatever 2/12/18)" string', source: 'Track Title (whatever 2/12/18)', expected: 'Track Title' +}, { + description: 'should not remove trailing "Live" word', + source: 'Track Title Live', + expected: 'Track Title Live' +}, { + description: 'should not remove "Live" word', + source: 'Track Live Title', + expected: 'Track Live Title' +}, { + description: 'should not remove "live" as a part of a word from string', + source: 'Fully Alive', + expected: 'Fully Alive' }]; /**