Revision 3e295388 snf-astakos-app/astakos/im/views.py

b/snf-astakos-app/astakos/im/views.py
431 431
    return response
432 432

  
433 433
@transaction.commit_manually
434
def activate(request, email_template_name='im/welcome_email.txt', helpdesk_email_template_name='im/helpdesk_notification.txt'):
434
def activate(request, greeting_email_template_name='im/welcome_email.txt', helpdesk_email_template_name='im/helpdesk_notification.txt'):
435 435
    """
436 436
    Activates the user identified by the ``auth`` request parameter, sends a welcome email
437 437
    and renews the user token.
......
455 455
        local_user = AstakosUser.objects.get(~Q(id = user.id), email=user.email, is_active=True)
456 456
    except AstakosUser.DoesNotExist:
457 457
        try:
458
            activate_func(user, email_template_name, helpdesk_email_template_name, verify_email=True)
458
            activate_func(user, greeting_email_template_name, helpdesk_email_template_name, verify_email=True)
459 459
            response = prepare_response(request, user, next, renew=True)
460 460
            transaction.commit()
461 461
            return response
......
473 473
            return index(request)
474 474
    else:
475 475
        try:
476
            user = switch_account_to_shibboleth(user, local_user, email_template_name)
476
            user = switch_account_to_shibboleth(user, local_user, greeting_email_template_name)
477 477
            response = prepare_response(request, user, next, renew=True)
478 478
            transaction.commit()
479 479
            return response

Also available in: Unified diff