Esempio n. 1
0
 def serve_file(self, request, fullpath, status_code=None):
     # Prefers text/plain response if possible
     content_type = None
     if 'text/plain' in request.content_types:
         content_type = 'text/plain'
     return file_response(request, fullpath, status_code=status_code,
                          cache_control=self.cache_control,
                          content_type=content_type)
Esempio n. 2
0
 def serve_file(self, request, fullpath, status_code=None):
     # Prefers text/plain response if possible
     content_type = None
     if 'text/plain' in request.content_types:
         content_type = 'text/plain'
     return file_response(request,
                          fullpath,
                          status_code=status_code,
                          cache_control=self.cache_control,
                          content_type=content_type)
Esempio n. 3
0
 def clip(self, request):
     c = request.urlargs['chunk_size']
     filepath = os.path.join(ASSET_DIR, 'clip.mp4')
     return wsgi.file_response(request, filepath, c)
Esempio n. 4
0
 def clip(self, request):
     c = request.urlargs['chunk_size']
     filepath = os.path.join(ASSET_DIR, 'clip.mp4')
     return wsgi.file_response(request, filepath, c)