quick_app, primitivus: update the connection mechanism to ask for non empty profile passwords
This commit is contained in:
parent
6a7f88858e
commit
fa430d5105
3 changed files with 46 additions and 8 deletions
|
|
@ -136,6 +136,9 @@ class QuickApp(object):
|
|||
if self.single_profile:
|
||||
self.profile = profile
|
||||
|
||||
self.launchAction(C.AUTHENTICATE_PROFILE_ID, {'caller': 'plug_profile'}, profile_key=profile)
|
||||
|
||||
def plug_profile_1(self, profile):
|
||||
###now we get the essential params###
|
||||
self.bridge.asyncGetParamA("JabberID", "Connection", profile_key=profile,
|
||||
callback=lambda _jid: self.plug_profile_2(_jid, profile), errback=self._getParamError)
|
||||
|
|
@ -152,7 +155,7 @@ class QuickApp(object):
|
|||
def plug_profile_4(self, watched, autoconnect, profile):
|
||||
if autoconnect and not self.bridge.isConnected(profile):
|
||||
#Does the user want autoconnection ?
|
||||
self.bridge.asyncConnect(profile, callback=lambda: self.plug_profile_5(watched, autoconnect, profile), errback=lambda ignore: log.error(_('Error during autoconnection')))
|
||||
self.bridge.asyncConnect(profile, callback=lambda dummy: self.plug_profile_5(watched, autoconnect, profile), errback=lambda ignore: log.error(_('Error during autoconnection')))
|
||||
else:
|
||||
self.plug_profile_5(watched, autoconnect, profile)
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue