Revision 40a0cd8b

b/snf-astakos-app/astakos/im/models.py
456 456
    @extended_groups.setter
457 457
    def extended_groups(self, groups):
458 458
        #TODO exceptions
459
        for name in groups:
459
        for name in (groups or ()):
460 460
            group = AstakosGroup.objects.get(name=name)
461 461
            self.membership_set.create(group=group)
462 462

  
......
803 803
    set_default_group(instance)
804 804
    # TODO handle socket.error & IOError
805 805
    register_users((instance,))
806
    instance.renew_token()
806
#     instance.renew_token()
807 807

  
808 808

  
809 809
def resource_post_save(sender, instance, created, **kwargs):
b/snf-astakos-app/astakos/im/views.py
385 385
                        logger.log(LOGGING_LEVEL, msg)
386 386
                if user and user.is_active:
387 387
                    next = request.POST.get('next', '')
388
                    response = prepare_response(request, user, next=next)
388 389
                    transaction.commit()
389
                    return prepare_response(request, user, next=next)
390
                    return response
390 391
                messages.add_message(request, status, message)
391 392
                transaction.commit()
392 393
                return render_response(on_success,

Also available in: Unified diff