diff options
Diffstat (limited to 'src/connection.rs')
| -rwxr-xr-x | src/connection.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/connection.rs b/src/connection.rs index 1561005..e0e788d 100755 --- a/src/connection.rs +++ b/src/connection.rs @@ -132,7 +132,7 @@ impl Connection { /// Gives title of current playing song pub fn now_playing(&mut self) -> Result<Option<String>> { - let song = self.conn.currentsong()?.unwrap(); + let song = self.conn.currentsong()?.unwrap_or_default(); if let Some(s) = song.title { if let Some(a) = song.artist { return Ok(Some(format!("{} - {}", s, a))); |
