comparison src/plugins/plugin_xep_0277.py @ 1838:b3b25dbac585

plugin XEP-0277: fix bad call after methods renaming
author Goffi <goffi@goffi.org>
date Thu, 28 Jan 2016 16:44:47 +0100
parents 68c0dc13d821
children 6e547dd7f38c
comparison
equal deleted inserted replaced
1837:7a8a19e4fa6c 1838:b3b25dbac585
505 yield self.host.trigger.point("XEP-0277_comments", client, mb_data, options) 505 yield self.host.trigger.point("XEP-0277_comments", client, mb_data, options)
506 506
507 try: 507 try:
508 comments_node = mb_data['comments_node'] 508 comments_node = mb_data['comments_node']
509 except KeyError: 509 except KeyError:
510 comments_node = self.getCommentNode(item_id) 510 comments_node = self.getCommentsNode(item_id)
511 else: 511 else:
512 if not comments_node: 512 if not comments_node:
513 raise exceptions.DataError(u"if comments_node is present, it must not be empty") 513 raise exceptions.DataError(u"if comments_node is present, it must not be empty")
514 514
515 try: 515 try:
516 comments_service = mb_data['comments_service'] 516 comments_service = mb_data['comments_service']
517 except KeyError: 517 except KeyError:
518 comments_service = self.getCommentService(client, service) 518 comments_service = self.getCommentsService(client, service)
519 519
520 try: 520 try:
521 yield self._p.createNode(comments_service, comments_node, options, profile_key=profile) 521 yield self._p.createNode(comments_service, comments_node, options, profile_key=profile)
522 except error.StanzaError as e: 522 except error.StanzaError as e:
523 if e.condition == 'conflict': 523 if e.condition == 'conflict':