[Pkg-javascript-commits] [node-static] 142/151: Update node-static.js
Tonnerre Lombard
tonnerre-guest at moszumanska.debian.org
Tue Jan 7 23:18:04 UTC 2014
This is an automated email from the git hooks/post-receive script.
tonnerre-guest pushed a commit to branch master
in repository node-static.
commit b8996094b67a232c6088a60af77dfa6718cec7ee
Author: valentinvieriu <valentin.vieriu at gmail.com>
Date: Fri Aug 23 20:23:23 2013 +0200
Update node-static.js
using regexp as a gzip option was not working. The content type parameter was missing
---
lib/node-static.js | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/node-static.js b/lib/node-static.js
index daadee7..380bbcd 100644
--- a/lib/node-static.js
+++ b/lib/node-static.js
@@ -211,7 +211,7 @@ Server.prototype.gzipOk = function(req, contentType) {
*/
Server.prototype.respondGzip = function(pathname, status, contentType, _headers, files, stat, req, res, finish) {
var that = this;
- if(files.length == 1 && this.gzipOk(req)) {
+ if(files.length == 1 && this.gzipOk(req,contentType)) {
var gzFile = files[0] + ".gz";
fs.stat(gzFile, function(e, gzStat) {
if(!e && gzStat.isFile()) {
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/node-static.git
More information about the Pkg-javascript-commits
mailing list