(request: WSGIRequest)
return _set_output(output)
Sets the given device as default output device.
Sets the given device as default output device.
Sets the given device as default output device .
def set_output(request: WSGIRequest) -> HttpResponse:
    """Sets the given device as default output device."""
    output = request.POST.get("value")
    if not output:
        return HttpResponseBadRequest("No output selected")

    if output == request.POST.get("output"):
        return HttpResponseBadRequest("Output unchanged")

    storage.set("output", output)

    return _set_output(output)
def set_output ( request : WSGIRequest ) -> HttpResponse : output = request . POST . get ( "value" ) if not output : return HttpResponseBadRequest ( "No output selected" ) if output == request . POST . get ( "output" ) : return HttpResponseBadRequest ( "Output unchanged" ) storage . set ( "output" , output ) return _set_output ( output )