From b828e4d52872814c7c6fcffeaf981b417bd6fcf0 Mon Sep 17 00:00:00 2001 From: Simon Persson Date: Fri, 6 Jan 2017 15:21:44 +0100 Subject: [PATCH] Improve log strings and never log to stdout. --- src/audio_backend/alsa.rs | 2 +- src/player.rs | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/audio_backend/alsa.rs b/src/audio_backend/alsa.rs index a5bbe720..95a4162f 100644 --- a/src/audio_backend/alsa.rs +++ b/src/audio_backend/alsa.rs @@ -6,7 +6,7 @@ pub struct AlsaSink(Option, String); impl Open for AlsaSink { fn open(device: Option<&str>) -> AlsaSink { - println!("Using alsa sink"); + info!("Using alsa sink"); let name = device.unwrap_or("default").to_string(); diff --git a/src/player.rs b/src/player.rs index ca496dbe..60a5ad01 100644 --- a/src/player.rs +++ b/src/player.rs @@ -180,12 +180,12 @@ fn find_available_alternative<'a>(session: &Session, track: &'a Track) -> Option fn load_track(session: &Session, track_id: SpotifyId) -> Option>>>> { let track = session.metadata::(track_id).await().unwrap(); - info!("Loading track {:?}", track.name); + info!("Loading track \"{}\"", track.name); let track = match find_available_alternative(session, &track) { Some(track) => track, None => { - warn!("Track {:?} is not available", track.name); + warn!("Track \"{}\" is not available", track.name); return None; } };