From 7678cf90a7e74f78a0651b07085aca5de2650a68 Mon Sep 17 00:00:00 2001 From: forcer Date: Tue, 20 Sep 2005 17:52:00 +0000 Subject: emms-info-track-description: Fall back to old behavior if no title and artist darcs-hash:20050920175244-2189f-b1e1413fde30472f7b6d974c7c4a2119f6523dd5.gz --- emms-info.el | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/emms-info.el b/emms-info.el index 8c1743c..ea427d6 100644 --- a/emms-info.el +++ b/emms-info.el @@ -93,9 +93,11 @@ Return zero otherwise." (defun emms-info-track-description (track) "Return a description of the current track." - (format "%s - %s" - (emms-track-get track 'info-artist) - (emms-track-get track 'info-title))) + (let ((artist (emms-track-get track 'info-artist)) + (title (emms-track-get track 'info-title))) + (if (and artist title) + (format "%s - %s" artist title) + (emms-track-simple-description track)))) (provide 'emms-info) ;;; emms-info.el ends here -- cgit v1.2.3