def __call__(self): body = self.render() if body is NOT_DONE_YET: return NOT_DONE_YET response = self.context.response headers = response['headers'] headers['Content-Type'] = self.content_type headers['Pragma'] = 'no-cache' headers['Cache-Control'] = 'no-cache' headers['Expires'] = http_date.build_http_date(0) response['body'] = body return response
def __call__(self): body = self.render() if body is NOT_DONE_YET: return NOT_DONE_YET response = self.context.response headers = response["headers"] headers["Content-Type"] = self.content_type headers["Pragma"] = "no-cache" headers["Cache-Control"] = "no-cache" headers["Expires"] = http_date.build_http_date(0) response["body"] = as_string(body) return response