Show More
@@ -33,7 +33,8 b' class FilesHandler(IPythonHandler):' | |||||
33 | if self.get_argument("download", False): |
|
33 | if self.get_argument("download", False): | |
34 | self.set_header('Content-Disposition','attachment; filename="%s"' % name) |
|
34 | self.set_header('Content-Disposition','attachment; filename="%s"' % name) | |
35 |
|
35 | |||
36 | if model['type'] == 'notebook' or name.endswith('.ipynb'): |
|
36 | # get mimetype from filename | |
|
37 | if name.endswith('.ipynb'): | |||
37 | self.set_header('Content-Type', 'application/json') |
|
38 | self.set_header('Content-Type', 'application/json') | |
38 | else: |
|
39 | else: | |
39 | cur_mime = mimetypes.guess_type(name)[0] |
|
40 | cur_mime = mimetypes.guess_type(name)[0] |
General Comments 0
You need to be logged in to leave comments.
Login now