try to make get_status work
This commit is contained in:
parent
32b3f683f4
commit
1095357c90
|
@ -208,10 +208,9 @@ class GajimRemote:
|
|||
],
|
||||
|
||||
'get_status': [
|
||||
_('Returns current status'),
|
||||
_('Returns current status (the global one unless account is specified)'),
|
||||
[
|
||||
(_('account'), _('if specified, returns status for this account; '
|
||||
'Else returns global status'), False)
|
||||
(_('account'), _(''), False)
|
||||
]
|
||||
],
|
||||
|
||||
|
@ -562,7 +561,7 @@ Type "%s help %s" for more info') % (args[argv_len][0], BASENAME, self.command))
|
|||
elif self.argv_len == 5:
|
||||
res = self.method(sys.argv[2], sys.argv[3], sys.argv[4])
|
||||
elif argv_len == 6:
|
||||
res = self.method(sys.argv[2], sys.argv[3], sys.argv[4],
|
||||
res = self.method(sys.argv[2], sys.argv[3], sys.argv[4],
|
||||
sys.argv[5])
|
||||
return res
|
||||
except Exception:
|
||||
|
|
|
@ -135,7 +135,7 @@ class SignalObject(DbusPrototype):
|
|||
'''get_status(account = None)
|
||||
returns status (show to be exact) which is the global one
|
||||
unless account is given'''
|
||||
account = self._get_real_arguments(args, 1)
|
||||
account = self._get_real_arguments(args, 1)[0]
|
||||
accounts = gajim.contacts.keys()
|
||||
if not account and len(accounts) == 1:
|
||||
# if there is only one account in roster, take it as default
|
||||
|
@ -532,6 +532,7 @@ class SignalObject(DbusPrototype):
|
|||
prefs_store = method(INTERFACE)(prefs_store)
|
||||
remove_contact = method(INTERFACE)(remove_contact)
|
||||
add_contact = method(INTERFACE)(add_contact)
|
||||
get_status = method(INTERFACE)(get_status)
|
||||
|
||||
class SessionBusNotPresent(Exception):
|
||||
'''This exception indicates that there is no session daemon'''
|
||||
|
|
Loading…
Reference in New Issue