Beispiel #1
0
def _json_payload(request):
    """Return a parsed JSON payload for the request.

    :raises PayloadError: if the body has no valid JSON body
    """
    try:
        return request.json_body
    except ValueError:
        raise PayloadError()
Beispiel #2
0
def _json_payload(request):
    try:
        return request.json_body
    except ValueError:
        raise PayloadError()