Changes between Initial Version and Version 1 of Ticket #30565


Ignore:
Timestamp:
Jun 14, 2019, 1:16:02 AM (6 years ago)
Author:
Chris Jerdonek
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #30565

    • Property Type UncategorizedCleanup/optimization
    • Property Version 2.2master
  • Ticket #30565 – Description

    initial v1  
    3838new_value = iter_content()
    3939}}}
     40
     41Here is the current code for `StreamingHttpResponse._set_streaming_content()`:
     42
     43{{{
     44#!python
     45def _set_streaming_content(self, value):
     46    # Ensure we can never iterate on "value" more than once.
     47    self._iterator = iter(value)
     48    if hasattr(value, 'close'):
     49        self._closable_objects.append(value)
     50}}}
     51
     52(from: https://github.com/django/django/blob/1564e42ad397021093585147875a21dae1a3b3fc/django/http/response.py#L376-L380)
     53
Back to Top