Socket
Socket
Sign inDemoInstall

send

Package Overview
Dependencies
Maintainers
3
Versions
65
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

send - npm Package Compare versions

Comparing version 1.0.0 to 1.1.0

10

HISTORY.md

@@ -0,1 +1,6 @@

1.1.0 / 2024-09-10
==================
* Changes from 0.19.0
1.0.0 / 2024-07-25

@@ -41,2 +46,7 @@ ==================

0.19.0 / 2024-09-10
===================
* Remove link renderization in html while redirecting
0.18.0 / 2022-03-23

@@ -43,0 +53,0 @@ ===================

7

index.js

@@ -384,4 +384,3 @@ /*!

var loc = encodeUrl(collapseLeadingSlashes(this.path + '/'))
var doc = createHtmlDocument('Redirecting', 'Redirecting to <a href="' + escapeHtml(loc) + '">' +
escapeHtml(loc) + '</a>')
var doc = createHtmlDocument('Redirecting', 'Redirecting to ' + escapeHtml(loc))

@@ -609,3 +608,4 @@ // redirect

fs.stat(path, function onstat (err, stat) {
if (err && err.code === 'ENOENT' && !extname(path) && path[path.length - 1] !== sep) {
var pathEndsWithSep = path[path.length - 1] === sep
if (err && err.code === 'ENOENT' && !extname(path) && !pathEndsWithSep) {
// not found, check extensions

@@ -616,2 +616,3 @@ return next(err)

if (stat.isDirectory()) return self.redirect(path)
if (pathEndsWithSep) return self.error(404)
self.emit('file', path, stat)

@@ -618,0 +619,0 @@ self.send(path, stat)

{
"name": "send",
"description": "Better streaming static file server with Range and conditional-GET support",
"version": "1.0.0",
"version": "1.1.0",
"author": "TJ Holowaychuk <tj@vision-media.ca>",

@@ -53,3 +53,3 @@ "contributors": [

"engines": {
"node": ">= 0.10"
"node": ">= 18"
},

@@ -56,0 +56,0 @@ "scripts": {

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