Mercurial > libervia-backend
comparison libervia/backend/memory/encryption.py @ 4341:e9971a4b0627
remove uses of twisted.internet.defer.returnValue
This function has been deprecated in Twisted 24.7.0.
author | Povilas Kanapickas <povilas@radix.lt> |
---|---|
date | Wed, 11 Dec 2024 01:17:09 +0200 |
parents | 0d7bb4df2343 |
children | 17fa953c8cd7 |
comparison
equal
deleted
inserted
replaced
4340:ea72364131d5 | 4341:e9971a4b0627 |
---|---|
485 @defer.inlineCallbacks | 485 @defer.inlineCallbacks |
486 def _on_menu_trust(cls, data, host, plg, profile): | 486 def _on_menu_trust(cls, data, host, plg, profile): |
487 client = host.get_client(profile) | 487 client = host.get_client(profile) |
488 peer_jid = jid.JID(data["jid"]).userhostJID() | 488 peer_jid = jid.JID(data["jid"]).userhostJID() |
489 ui = yield client.encryption.get_trust_ui(peer_jid, plg.namespace) | 489 ui = yield client.encryption.get_trust_ui(peer_jid, plg.namespace) |
490 defer.returnValue({"xmlui": ui.toXml()}) | 490 return {"xmlui": ui.toXml()} |
491 | 491 |
492 ## Triggers ## | 492 ## Triggers ## |
493 | 493 |
494 def set_encryption_flag(self, mess_data): | 494 def set_encryption_flag(self, mess_data): |
495 """Set "encryption" key in mess_data if session with destinee is encrypted""" | 495 """Set "encryption" key in mess_data if session with destinee is encrypted""" |