                  response.raw_content = self.filter_response(response.raw_content)
              else:
                  response.content = self.filter_response(response.content)
  
          except ErrorResponse, response:
              # Prepare response for the response cycle.
              self.prepare_response(response)
  
          # `final` is the last opportunity to temper with the response, or even
          # completely replace it.
 
</s> remove             # TODO: ugly
 </s> add             # TODO: ugly hack to handle both HttpResponse and Response.  </s> remove         except ErrorResponse, response:
 </s> add         except ImmediateResponse, response: </s> remove         except ErrorResponse, response:
 </s> add         except ImmediateResponse, response: </s> remove         except ErrorResponse, response:
 </s> add         except ImmediateResponse, response: </s> remove         # TODO: renderer *could* override media_type in .render() if required.
 </s> add 
        except ImmediateResponse, response:
                  response.raw_content = self.filter_response(response.raw_content)
              else:
                  response.content = self.filter_response(response.content)
  
        except ImmediateResponse, response:
              # Prepare response for the response cycle.
              self.prepare_response(response)
  
          # `final` is the last opportunity to temper with the response, or even
          # completely replace it.
keep keep keep keep replace keep keep keep keep keep
 cleaned a bit Response/ResponseMixin code, added some documentation + renamed ErrorResponse to ImmediateResponse 
djangorestframework/views.py