diff options
author | jao <jao@gnu.org> | 2022-02-03 20:04:58 +0000 |
---|---|---|
committer | jao <jao@gnu.org> | 2022-02-03 20:04:58 +0000 |
commit | 88996863d706c5a23b82537612f932419b48915e (patch) | |
tree | 9aa9d81abd69f189427cb2995892af3a474135c4 /lib | |
parent | 81755845fe9fbd35154c73d102db9da0dba4c010 (diff) | |
download | elibs-88996863d706c5a23b82537612f932419b48915e.tar.gz elibs-88996863d706c5a23b82537612f932419b48915e.tar.bz2 |
jao-lyrics: more informative error message
Diffstat (limited to 'lib')
-rw-r--r-- | lib/media/jao-lyrics.el | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/lib/media/jao-lyrics.el b/lib/media/jao-lyrics.el index dd85da1..5008fae 100644 --- a/lib/media/jao-lyrics.el +++ b/lib/media/jao-lyrics.el @@ -1,6 +1,6 @@ ;; jao-lyrics.el -- simple show lyrics using glyrc -;; Copyright (C) 2009, 2010, 2017, 2019, 2020 Jose Antonio Ortega Ruiz +;; Copyright (C) 2009, 2010, 2017, 2019, 2020, 2022 Jose Antonio Ortega Ruiz ;; Author: Jose Antonio Ortega Ruiz <jao@gnu.org> ;; Start date: Sat Jul 04, 2009 13:41 @@ -121,9 +121,11 @@ ;;;###autoload (defun jao-show-lyrics (&optional force info-function) (interactive "P") - (let* ((a/t (funcall (or info-function - jao-lyrics--info-function - jao-lyrics-info-function))) + (let* ((fun (or info-function + jao-lyrics--info-function + jao-lyrics-info-function)) + (a/t (when fun (funcall fun))) + (_ (unless a/t (user-error "No info returned by %s" fun))) (artist (car a/t)) (title (cdr a/t)) (artist (if force (read-string "Artist: " artist) artist)) |