diff options
-rw-r--r-- | emms-player-mpd.el | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/emms-player-mpd.el b/emms-player-mpd.el index e014aa0..ef07624 100644 --- a/emms-player-mpd.el +++ b/emms-player-mpd.el @@ -686,12 +686,10 @@ Execute CALLBACK with CLOSURE as its first argument when done." Execute CALLBACK with CLOSURE as its first argument when done." ;; This is useful with emms-streams.el - (condition-case nil - (progn - (require 'url) - (with-temp-buffer - (url-insert-file-contents url) - (emms-player-mpd-add-buffer-contents closure callback))) + (if (fboundp 'url-insert-file-contents) + (with-temp-buffer + (url-insert-file-contents url) + (emms-player-mpd-add-buffer-contents closure callback)) (error (message (concat "You need to install url.el so that" " Emms can retrieve this stream"))))) |