contrib/gpio-mpd-rpi: improves debug when server has problems
[nit.git] / contrib / physical_interface_for_mpd_on_rpi / physical_interface_for_mpd_on_rpi.nit
index 455d109..ded48fb 100644 (file)
@@ -348,7 +348,10 @@ do
        var status = mpd.status
        var playing = false
        if status != null then
-               playing = status.state == "play"
+               playing = status.playing
+       else
+               print "Cannot get state"
+               return
        end
 
        if playing then