Closed benoitbryon closed 11 years ago
Problem partly solved via file wrappers: the view instanciates the file wrapper with just what is needed. Then, if the download response actually streams the file (i.e. if it is not intercepted by some middleware), it uses file wrapper's attribute (which can be lazy).
In current implementation, views populate the response attributes. But, if some optimizations are configured, the response may be captured and altered. As the file content, response attributes shouldn't be loaded in the view, whenever possible.