Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def unblock_contact(self, contact):
def callback(memberships):
contact._set_memberships(memberships)
self.emit('contact-unblocked', contact)
uc = scenario.UnblockContactScenario(self._sharing,
(callback,),
(self.__common_errback,))
uc.account = contact.account
uc.network = contact.network_id
uc.membership = contact.memberships
uc()
def unblock_contact(self, contact, done_cb=None, failed_cb=None):
def callback(memberships):
contact._set_memberships(memberships)
self.__common_callback('contact-unblocked', done_cb, contact)
uc = scenario.UnblockContactScenario(self._sharing,
(callback,),
(self.__common_errback, failed_cb))
uc.account = contact.account
uc.network = contact.network_id
uc.membership = contact.memberships
uc()
def unblock_contact(self, contact, done_cb=None, failed_cb=None):
def callback(memberships):
contact._set_memberships(memberships)
self.__common_callback('contact-unblocked', done_cb, contact)
uc = scenario.UnblockContactScenario(self._sharing,
(callback,),
(self.__common_errback, failed_cb))
uc.account = contact.account
uc.network = contact.network_id
uc.membership = contact.memberships
uc()
def unblock_contact(self, contact, done_cb=None, failed_cb=None):
def callback(memberships):
contact._set_memberships(memberships)
self.__common_callback('contact-unblocked', done_cb, contact)
uc = scenario.UnblockContactScenario(self._sharing,
(callback,),
(self.__common_errback, failed_cb))
uc.account = contact.account
uc.network = contact.network_id
uc.membership = contact.memberships
uc()