Mercurial > libervia-backend
comparison sat/plugins/plugin_misc_text_commands.py @ 3156:0318802dfe28
core (memory/disco): fixed checkFeature return Failure:
it seems that instanciating a Failure with a class name is not working anymore, so the
exceptions.FeatureNotFound is instanciated now.
author | Goffi <goffi@goffi.org> |
---|---|
date | Tue, 04 Feb 2020 19:59:42 +0100 |
parents | 559a625a236b |
children | 8418e0c83ed7 |
comparison
equal
deleted
inserted
replaced
3155:3a8755fdc78d | 3156:0318802dfe28 |
---|---|
369 target_jid.resource = self.host.memory.getMainResource(client, target_jid) | 369 target_jid.resource = self.host.memory.getMainResource(client, target_jid) |
370 | 370 |
371 whois_msg = [_("whois for %(jid)s") % {"jid": target_jid}] | 371 whois_msg = [_("whois for %(jid)s") % {"jid": target_jid}] |
372 | 372 |
373 d = defer.succeed(None) | 373 d = defer.succeed(None) |
374 for ignore, callback in self._whois: | 374 for __, callback in self._whois: |
375 d.addCallback( | 375 d.addCallback( |
376 lambda ignore: callback(client, whois_msg, mess_data, target_jid) | 376 lambda __: callback(client, whois_msg, mess_data, target_jid) |
377 ) | 377 ) |
378 | 378 |
379 def feedBack(ignore): | 379 def feedBack(__): |
380 self.feedBack(client, "\n".join(whois_msg), mess_data) | 380 self.feedBack(client, "\n".join(whois_msg), mess_data) |
381 return False | 381 return False |
382 | 382 |
383 d.addCallback(feedBack) | 383 d.addCallback(feedBack) |
384 return d | 384 return d |