diff --git a/core/modules/server/routes/get-file.js b/core/modules/server/routes/get-file.js index 5bc4e09e1..3429c4cd2 100644 --- a/core/modules/server/routes/get-file.js +++ b/core/modules/server/routes/get-file.js @@ -38,7 +38,7 @@ exports.handler = function(request,response,state) { } else { status = 200; content = content; - type = $tw.config.fileExtensionInfo[extension] || "application/octet-stream"; + type = ($tw.config.fileExtensionInfo[extension] ? $tw.config.fileExtensionInfo[extension].type : "application/octet-stream"); } response.writeHead(status,{ "Content-Type": type