#NEWLINE# @ request_method_decorator #NEWLINE# def _update( resource , data = None , query_args = { #NEWLINE# #INDENT# #NEWLINE# #UNINDENT# } , * args , **kwargs ) : #NEWLINE# #INDENT# "Generate a PUT request on a resource.\n\n    Unlike other methods, any additional query args must be passed in\n    using the 'query_args' parameter, since kwargs is used for the\n    fields which will be sent.\n\n    Review Board expects ``extra_data`` fields to be sent as\n    ``extra_data.field_name``, which cannot be passed as a raw literal in\n    Python. Fields like this would have to be added to a dict and splatted.\n    However, this function also accepts keyword arguments of the form\n    ``extra_data__field_name``, which will be rewritten to fields of the form\n    ``extra_data.field_name``.\n    " #NEWLINE# request = HttpRequest ( resource . _links [ 'update' ] [ 'href' ] , method = 'PUT' , query_args = query_args ) #NEWLINE# if ( data is None ) : #NEWLINE# #INDENT# data = { #NEWLINE# #INDENT# #NEWLINE# #UNINDENT# } #NEWLINE# #UNINDENT# kwargs . update ( data ) #NEWLINE# for ( name , value ) in _preprocess_fields ( kwargs ) : #NEWLINE# #INDENT# request . add_field ( name , value ) #NEWLINE# #UNINDENT# return request