summaryrefslogtreecommitdiff
path: root/src/tabs.py
diff options
context:
space:
mode:
authormathieui <mathieui@mathieui.net>2012-04-18 00:10:57 +0200
committermathieui <mathieui@mathieui.net>2012-04-18 00:10:57 +0200
commitd049ea753497a255e0554e37c4c81e15541ed08f (patch)
tree89be42def72da704c78027600765139566366386 /src/tabs.py
parent22cd80feb52d539e8aef5a252c75f75cf1f04c5b (diff)
downloadpoezio-d049ea753497a255e0554e37c4c81e15541ed08f.tar.gz
poezio-d049ea753497a255e0554e37c4c81e15541ed08f.tar.bz2
poezio-d049ea753497a255e0554e37c4c81e15541ed08f.tar.xz
poezio-d049ea753497a255e0554e37c4c81e15541ed08f.zip
Do not split args in command_info as it is not needed
Diffstat (limited to 'src/tabs.py')
-rw-r--r--src/tabs.py24
1 files changed, 13 insertions, 11 deletions
diff --git a/src/tabs.py b/src/tabs.py
index 9a8f3794..9f67ab29 100644
--- a/src/tabs.py
+++ b/src/tabs.py
@@ -693,18 +693,20 @@ class MucTab(ChatTab):
self.input.refresh()
def command_info(self, arg):
- args = common.shell_split(arg)
- if len(args) != 1:
- return self.core.information("Info command takes only 1 argument")
- user = self.get_user_by_name(args[0])
+ """
+ /info <nick>
+ """
+ if not arg:
+ return self.command_help('info')
+ user = self.get_user_by_name(arg)
if not user:
- return self.core.information("Unknown user: %s" % args[0])
- info = '%s%s: show: %s, affiliation: %s, role: %s%s' % (args[0],
- ' (%s)' % user.jid if user.jid else '',
- user.show or 'Available',
- user.role or 'None',
- user.affiliation or 'None',
- '\n%s' % user.status if user.status else '')
+ return self.core.information("Unknown user: %s" % arg)
+ info = '%s%s: show: %s, affiliation: %s, role: %s%s' % (arg,
+ ' (%s)' % user.jid if user.jid else '',
+ user.show or 'Available',
+ user.role or 'None',
+ user.affiliation or 'None',
+ '\n%s' % user.status if user.status else '')
self.core.information(info, 'Info')
def command_configure(self, arg):