X-Git-Url: https://git.kaliko.me/?a=blobdiff_plain;f=musicpd.py;h=f480acdd0f5897b91a8eae8e0783d1ba55e86fe9;hb=4fdeb581beba85d9157fac917c48ae08dda4c941;hp=864337e711baeb4ffa1cf05841df5c2acd87d3c0;hpb=e1bde448be82c3cedaadd6fa0f5447d250ecefb2;p=python-musicpd.git diff --git a/musicpd.py b/musicpd.py index 864337e..f480acd 100644 --- a/musicpd.py +++ b/musicpd.py @@ -22,7 +22,7 @@ HELLO_PREFIX = "OK MPD " ERROR_PREFIX = "ACK " SUCCESS = "OK" NEXT = "list_OK" -VERSION = '0.3.1b' +VERSION = '0.4.0pr0' class MPDError(Exception): @@ -131,6 +131,7 @@ class MPDClient(object): "searchaddpl": self._fetch_nothing, "update": self._fetch_item, "rescan": self._fetch_item, + "readcomments": self._fetch_object, # Sticker Commands "sticker get": self._fetch_item, "sticker set": self._fetch_nothing, @@ -145,6 +146,7 @@ class MPDClient(object): # Audio Output Commands "disableoutput": self._fetch_nothing, "enableoutput": self._fetch_nothing, + "toggleoutput": self._fetch_nothing, "outputs": self._fetch_outputs, # Reflection Commands "commands": self._fetch_list, @@ -440,7 +442,7 @@ class MPDClient(object): self._rfile.close() if hasattr(self._wfile, 'close'): self._wfile.close() - if isinstance(self._sock, socket.socket): + if hasattr(self._sock, 'close'): self._sock.close() self._reset()