Comparing version 21.0.0-rc.2 to 21.0.0-rc.3
@@ -123,4 +123,3 @@ | ||
, savePath = (reqOpts.tmp || req.opts.tmp) + "-" + (seq++) | ||
return new Writable({ | ||
, writable = { | ||
write: function(chunk, enc, cb) { | ||
@@ -222,4 +221,13 @@ var buf, bufNum, i, j | ||
} | ||
}) | ||
} | ||
if (reqOpts && reqOpts.epilogue) { | ||
writable.final = function(cb) { | ||
req.epilogue = Buffer.concat(bufs).toString("utf8", 4) | ||
cb() | ||
} | ||
} | ||
return new Writable(writable) | ||
function saveTo(stream) { | ||
@@ -226,0 +234,0 @@ fileStream = ( |
{ | ||
"name": "litejs", | ||
"version": "21.0.0-rc.2", | ||
"version": "21.0.0-rc.3", | ||
"description": "Full-stack web framework in a tiny package", | ||
@@ -5,0 +5,0 @@ "license": "MIT", |
@@ -226,2 +226,3 @@ | ||
function app(req, res, _next) { | ||
if (res.send) return next() | ||
var oldPath, oldUrl | ||
@@ -587,5 +588,7 @@ , tryCatch = true | ||
if (!map || !map.port) return | ||
net = server["_" + proto] = require(proto)[ | ||
proto == "http2" ? "createSecureServer" : "createServer" | ||
](map, map.redirect ? forceHttps : server) | ||
net = server["_" + proto] = ( | ||
proto == "http" ? | ||
require(proto).createServer(map.redirect ? forceHttps : server) : | ||
require(proto).createSecureServer(map, map.redirect ? forceHttps : server) | ||
) | ||
.listen(map.port, map.host || "0.0.0.0", function() { | ||
@@ -603,3 +606,3 @@ var addr = this.address() | ||
server["_" + proto] | ||
net | ||
.on("newSession", function(id, data, cb) { | ||
@@ -606,0 +609,0 @@ sessionStore[id] = data |
66159
14
2236
12