Socket
Socket
Sign inDemoInstall

serve-static

Package Overview
Dependencies
Maintainers
6
Versions
66
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

serve-static - npm Package Compare versions

Comparing version 1.6.3 to 1.6.4

7

HISTORY.md

@@ -0,5 +1,10 @@

1.6.4 / 2014-10-08
==================
* Fix redirect loop when index file serving disabled
1.6.3 / 2014-09-24
==================
* deps: send@0.9.2
* deps: send@0.9.3
- deps: etag@~1.4.0

@@ -6,0 +11,0 @@

@@ -65,4 +65,5 @@ /*!

var path = parseurl(req).pathname
var hasTrailingSlash = originalUrl.pathname[originalUrl.pathname.length - 1] === '/'
if (path === '/' && originalUrl.pathname[originalUrl.pathname.length - 1] !== '/') {
if (path === '/' && !hasTrailingSlash) {
// make sure redirect occurs at mount

@@ -78,2 +79,6 @@ path = ''

stream.on('directory', function redirect() {
if (hasTrailingSlash) {
return next()
}
originalUrl.pathname += '/'

@@ -80,0 +85,0 @@

4

package.json
{
"name": "serve-static",
"description": "Serve static files",
"version": "1.6.3",
"version": "1.6.4",
"author": "Douglas Christopher Wilson <doug@somethingdoug.com>",

@@ -18,3 +18,3 @@ "license": "MIT",

"should": "~4.0.0",
"supertest": "~0.13.0"
"supertest": "~0.14.0"
},

@@ -21,0 +21,0 @@ "files": [

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc