comparison src/core/sat_main.py @ 949:b4cd968e30fb

core: fixed bad closure in connection intialisation sequence (profileConnected in plugins were not called correctly)
author Goffi <goffi@goffi.org>
date Mon, 31 Mar 2014 12:23:13 +0200
parents e1842ebcb2f3
children 027a054c6dda
comparison
equal deleted inserted replaced
948:abd3a75d629c 949:b4cd968e30fb
258 current.startService() 258 current.startService()
259 259
260 d = current.getConnectionDeferred() 260 d = current.getConnectionDeferred()
261 d.addCallback(lambda dummy: current.roster.got_roster) # we want to be sure that we got the roster 261 d.addCallback(lambda dummy: current.roster.got_roster) # we want to be sure that we got the roster
262 for callback in plugin_conn_cb: 262 for callback in plugin_conn_cb:
263 d.addCallback(lambda dummy: callback(profile)) 263 d.addCallback(lambda dummy, callback=callback: callback(profile))
264 return d 264 return d
265 265
266 self.memory.startProfileSession(profile) 266 self.memory.startProfileSession(profile)
267 return self.memory.loadIndividualParams(profile).addCallback(afterMemoryInit) 267 return self.memory.loadIndividualParams(profile).addCallback(afterMemoryInit)
268 268