From 16457ad64150c19b6acc06f35d9bc2cddfdc5b80 Mon Sep 17 00:00:00 2001 From: Jas Singh Date: Thu, 31 Oct 2024 02:24:33 -0700 Subject: [PATCH] Fixed an issue that would cause an empty media label to render when none were active. (#412) --- modules/bar/media/helpers.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/modules/bar/media/helpers.ts b/modules/bar/media/helpers.ts index b94c4c4..f34a9ee 100644 --- a/modules/bar/media/helpers.ts +++ b/modules/bar/media/helpers.ts @@ -63,7 +63,8 @@ export const generateMediaLabel = ( const mediaLabel = truncation_size.value > 0 ? truncatedLabel.substring(0, truncation_size.value) : truncatedLabel; - return mediaLabel; + + return mediaLabel.length ? mediaLabel : 'Media'; } else { songIcon.value = getIconForPlayer(activePlayer.value?.identity || ''); return `Media`;