refactor(main) isGzip: pReq -> req

This commit is contained in:
coderaiser 2014-08-13 06:34:01 -04:00
parent 19183b3506
commit 3921cc0137

View file

@ -384,7 +384,7 @@
p.status = FILE_NOT_FOUND;
if (!p.data && error)
p.data = error.toString();
p.data = error.message;
sendResponse(p);
}
@ -427,14 +427,15 @@
return pathname;
}
function isGZIP(pReq) {
var lEnc, lGZIP;
if (pReq) {
lEnc = pReq.headers['accept-encoding'] || '';
lGZIP = lEnc.match(/\bgzip\b/);
function isGZIP(req) {
var enc, is;
if (req) {
enc = req.headers['accept-encoding'] || '';
is = enc.match(/\bgzip\b/);
}
return lGZIP;
return is;
}
function setHeader(header, response) {