def register_onaccept(form):
    """ Tasks to be performed after a new user registers """

    # Process Custom Fields
    req_vars = form.request_vars
    position = req_vars.get("position", "")
    reason = req_vars.get("reason", "")
    db = current.db
    table = db.auth_user
    db(table.id == form.vars.id).update(comments = "%s | %s" % (position, reason))

# =============================================================================
dataset/ETHPy150Open sahana/eden/modules/templates/DRRPP/controllers.py/register_onaccept/original