Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

0http

Package Overview
Dependencies
Maintainers
1
Versions
35
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

0http - npm Package Compare versions

Comparing version 3.4.4 to 3.5.0

lib/router/sequential.d.ts

3

index.js

@@ -9,3 +9,4 @@ const http = require('http')

server.prioRequestsProcessing = config.prioRequestsProcessing && (server instanceof httpServer || server instanceof httpsServer)
server.prioRequestsProcessing =
config.prioRequestsProcessing && (server instanceof httpServer || server instanceof httpsServer)

@@ -12,0 +13,0 @@ if (server.prioRequestsProcessing) {

@@ -1,2 +0,2 @@

function next (middlewares, req, res, index, routers = {}, defaultRoute, errorHandler) {
function next(middlewares, req, res, index, routers = {}, defaultRoute, errorHandler) {
const middleware = middlewares[index]

@@ -11,3 +11,3 @@ if (!middleware) {

function step (err) {
function step(err) {
if (err) {

@@ -14,0 +14,0 @@ return errorHandler(err, req, res)

@@ -81,4 +81,4 @@ const Trouter = require('trouter')

delete req.preRouterUrl
delete req.preRouterPath
req.preRouterUrl = undefined
req.preRouterPath = undefined

@@ -85,0 +85,0 @@ return step()

@@ -8,5 +8,3 @@ module.exports = (req, url) => {

if (query[name]) {
Array.isArray(query[name])
? query[name].push(value)
: (query[name] = [query[name], value])
Array.isArray(query[name]) ? query[name].push(value) : (query[name] = [query[name], value])
} else {

@@ -13,0 +11,0 @@ query[name] = value

{
"name": "0http",
"version": "v3.4.4",
"version": "v3.5.0",
"description": "Cero friction HTTP request router. The need for speed!",
"main": "index.js",
"scripts": {
"lint": "npx standard",
"format": "npx standard --fix",
"lint": "npx rome ci . --semicolons=as-needed",
"format": "npx rome format . --semicolons=as-needed --write",
"test": "cross-env PORT=3000 NODE_ENV=testing npx nyc --check-coverage --lines 85 node ./node_modules/mocha/bin/mocha tests/*.test.js"

@@ -31,2 +31,3 @@ },

"devDependencies": {
"@types/node": "^18.14.4",
"body-parser": "^1.20.1",

@@ -47,6 +48,7 @@ "chai": "^4.3.7",

"dependencies": {
"lru-cache": "^7.14.1",
"lru-cache": "^7.18.1",
"regexparam": "^2.0.1",
"trouter": "^3.2.0"
}
}
"trouter": "^3.2.1"
},
"types": "./index.d.ts"
}

@@ -8,3 +8,3 @@ # Introduction

<img src="docs/0http-logo.svg" width="200">
<img src="docs/0http-logo.svg" width="400">

@@ -11,0 +11,0 @@ Zero friction HTTP framework:

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