Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fix mime type for server

  • Loading branch information...
commit 3e59f61e3a6d4d48aeafc31b611eb3c35e9bbbe1 1 parent e39cf51
@carhartl authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  server.js
View
2  server.js
@@ -15,7 +15,7 @@ http.createServer(function(request, response) {
return;
}
- response.writeHead(200);
+ response.writeHead(200, filename.match(/\.js$/) ? { 'Content-Type': 'text/javascript' } : {});
response.write(file, 'utf-8');
response.end();
});
Please sign in to comment.
Something went wrong with that request. Please try again.