(request)
return render(request, 'pygmy/dashboard.html', context=context)
Returns the list of signed up user links
Returns the list of signed up user links
Returns the list of signed up user links
def dashboard(request):
    """Returns the list of signed up user links"""
    access_token = request.COOKIES.get(AUTH_COOKIE_NAME)
    if not access_token:
        return render(request, '400.html', context=INVALID_TOKEN, status=400)
    pygmy_client = pygmy_client_object(settings, request)
    try:
        links = pygmy_client.list_links(access_token=access_token)
    except UnAuthorized as e:
        return render(request,
                      'unauthorized.html',
                      context=API_ERROR(e.args[0]),
                      status=403)
    except ObjectNotFound as e:
        return render(
            request, '404.html', context=API_ERROR(e.args[0]), status=404)
    context = dict(links=links)
    return render(request, 'pygmy/dashboard.html', context=context)
def dashboard ( request ) : access_token = request . COOKIES . get ( AUTH_COOKIE_NAME ) if not access_token : return render ( request , '400.html' , context = INVALID_TOKEN , status = 400 ) pygmy_client = pygmy_client_object ( settings , request ) try : links = pygmy_client . list_links ( access_token = access_token ) except UnAuthorized as e : return render ( request , 'unauthorized.html' , context = API_ERROR ( e . args [ 0 ] ) , status = 403 ) except ObjectNotFound as e : return render ( request , '404.html' , context = API_ERROR ( e . args [ 0 ] ) , status = 404 ) context = dict ( links = links ) return render ( request , 'pygmy/dashboard.html' , context = context )