Skip to content

Commit f5be3de

Browse files
Removes .html and .css omission
Revert this commit once we merge sintaxi/terraform#125
1 parent d64c4e3 commit f5be3de

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/middleware.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -323,7 +323,7 @@ exports.mwl = function(req, rsp, next){
323323
// `.js` (Browserify) are actually being used to specify
324324
// source files
325325

326-
if (['html', 'css', 'js'].indexOf(ext) === -1) {
326+
if (['js'].indexOf(ext) === -1) {
327327
if (terraform.helpers.processors["html"].indexOf(ext) !== -1 || terraform.helpers.processors["css"].indexOf(ext) !== -1 || terraform.helpers.processors["js"].indexOf(ext) !== -1) {
328328
notFound(req, rsp, next)
329329
} else {
@@ -345,7 +345,7 @@ exports.static = function(req, res, next) {
345345
var redirect = true
346346

347347
if ('GET' != req.method && 'HEAD' != req.method) return next()
348-
if (['html', 'css', 'js'].indexOf(path.extname(req.url).replace(/^\./, '')) !== -1) return next()
348+
if (['js'].indexOf(path.extname(req.url).replace(/^\./, '')) !== -1) return next()
349349

350350
var pathn = parse(req).pathname;
351351
var pause = utilsPause(req);

0 commit comments

Comments
 (0)