jp (event): fixed crash on missing item in get and inviteeGet by making it mandatory.

This commit is contained in:
Goffi 2018-06-21 01:21:44 +02:00
commit 485dfdf705
2 changed files with 3 additions and 2 deletions

View file

@ -742,6 +742,7 @@ class CommandBase(object):
- pubsub_flags(iterable[unicode]): tuple of flags to set pubsub options, can be:
C.SERVICE: service is required
C.NODE: node is required
C.ITEM: item is required
C.SINGLE_ITEM: only one item is allowed
@attribute need_loop(bool): to set by commands when loop is needed
"""

View file

@ -42,7 +42,7 @@ class Get(base.CommandBase):
host,
'get',
use_output=C.OUTPUT_DICT,
use_pubsub=True, pubsub_flags={C.NODE, C.SINGLE_ITEM},
use_pubsub=True, pubsub_flags={C.NODE, C.ITEM, C.SINGLE_ITEM},
use_verbose=True,
help=_(u'get event data'))
self.need_loop=True
@ -152,7 +152,7 @@ class InviteeGet(base.CommandBase):
host,
'get',
use_output=C.OUTPUT_DICT,
use_pubsub=True, pubsub_flags={C.NODE},
use_pubsub=True, pubsub_flags={C.NODE, C.ITEM, C.SINGLE_ITEM},
use_verbose=True,
help=_(u'get event attendance'))
self.need_loop=True