comparison sat_frontends/jp/base.py @ 3408:19bc03743aeb

jp (file/send): don't add main resource to bare jid anymore: bare jid sending is now managed by backend (at least for Jingle), so resource must not be added automatically anymore.
author Goffi <goffi@goffi.org>
date Thu, 12 Nov 2020 14:53:16 +0100
parents 2f0be2b7de68
children 4ca5bc6b44b6
comparison
equal deleted inserted replaced
3407:2f0be2b7de68 3408:19bc03743aeb
872 f"before using jp, or use --connect option")) 872 f"before using jp, or use --connect option"))
873 self.quit(1) 873 self.quit(1)
874 874
875 async def get_full_jid(self, param_jid): 875 async def get_full_jid(self, param_jid):
876 """Return the full jid if possible (add main resource when find a bare jid)""" 876 """Return the full jid if possible (add main resource when find a bare jid)"""
877 # TODO: to be removed, bare jid should work with all commands, notably for file
878 # as backend now handle jingles message initiation
877 _jid = JID(param_jid) 879 _jid = JID(param_jid)
878 if not _jid.resource: 880 if not _jid.resource:
879 #if the resource is not given, we try to add the main resource 881 #if the resource is not given, we try to add the main resource
880 main_resource = await self.bridge.getMainResource(param_jid, self.profile) 882 main_resource = await self.bridge.getMainResource(param_jid, self.profile)
881 if main_resource: 883 if main_resource: