From 8107e3f49ef959061d7fe0e04ef2f6eda01df354 Mon Sep 17 00:00:00 2001 From: liam4 Date: Wed, 21 Jun 2017 19:04:48 +0000 Subject: Ugh!! --- src/playlist-utils.js | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'src/playlist-utils.js') diff --git a/src/playlist-utils.js b/src/playlist-utils.js index ff19ea9..13c6003 100644 --- a/src/playlist-utils.js +++ b/src/playlist-utils.js @@ -130,6 +130,7 @@ function parsePathString(pathString) { return pathParts } +// TODO: Are these two functions actually useful?? function getGroupTitle(group) { return group[0] } @@ -142,11 +143,16 @@ function isGroup(array) { return Array.isArray(array[1]) } +function isTrack(array) { + return typeof array[1] === 'string' +} + module.exports = { flattenPlaylist, filterPlaylistByPathString, filterPlaylistByPath, removeGroupByPathString, removeGroupByPath, getPlaylistTreeString, parsePathString, - getGroupTitle, getGroupContents + getGroupTitle, getGroupContents, + isGroup, isTrack } -- cgit 1.3.0-6-gf8a5