summaryrefslogtreecommitdiff
path: root/plugins/mpd_client.py
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/mpd_client.py')
-rw-r--r--plugins/mpd_client.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/plugins/mpd_client.py b/plugins/mpd_client.py
index 47bbdf29..c215e971 100644
--- a/plugins/mpd_client.py
+++ b/plugins/mpd_client.py
@@ -9,7 +9,7 @@ import mpd
class Plugin(BasePlugin):
def init(self):
for _class in (tabs.ConversationTab, tabs.MucTab, tabs.PrivateTab):
- self.add_tab_command(_class, 'mpd', self.command_mpd,
+ self.api.add_tab_command(_class, 'mpd', self.command_mpd,
usage='[full]',
help='Sends a message showing the current song of an MPD instance. If full is provided, the message is more verbose.',
short='Send the MPD status',
@@ -34,8 +34,8 @@ class Plugin(BasePlugin):
current_time = float(c.status()['elapsed'])
pourcentage = int(current_time / float(current['time']) * 10)
s += ' \x192}[\x191}' + '-'*(pourcentage-1) + '\x193}+' + '\x191}' + '-' * (10-pourcentage-1) + '\x192}]\x19o'
- if not self.core.send_message('%s' % (s,)):
- self.core.information('Cannot send result (%s)' % s, 'Error')
+ if not self.api.send_message('%s' % (s,)):
+ self.api.information('Cannot send result (%s)' % s, 'Error')
def completion_mpd(self, the_input):
return the_input.auto_completion(['full'], quotify=False)