mirror of
https://github.com/powerline/powerline.git
synced 2025-07-26 23:35:04 +02:00
Merge pull request #1501 from mook/1500-mpd-utf8
[Players - mpd] Use Unicode where available
This commit is contained in:
commit
78c6c730ca
@ -189,6 +189,10 @@ class MpdPlayerSegment(PlayerSegment):
|
|||||||
'total': now_playing[3],
|
'total': now_playing[3],
|
||||||
}
|
}
|
||||||
else:
|
else:
|
||||||
|
try:
|
||||||
|
client = mpd.MPDClient(use_unicode=True)
|
||||||
|
except TypeError:
|
||||||
|
# python-mpd 1.x does not support use_unicode
|
||||||
client = mpd.MPDClient()
|
client = mpd.MPDClient()
|
||||||
client.connect(host, port)
|
client.connect(host, port)
|
||||||
if password:
|
if password:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user