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

rjweb-server

Package Overview
Dependencies
Maintainers
1
Versions
375
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

rjweb-server - npm Package Compare versions

Comparing version 0.6.6 to 0.6.7

16

index.js

@@ -31,3 +31,3 @@ const { getAllFiles, getAllFilesFilter } = require('./utils/getAllFiles.js')

if (!types.includes(type)) throw TypeError(`No Valid Request Type: ${type}\nPossible Values: ${types.toString()}`)
this.urls[url] = {
this.urls[type + url] = {
array: url.split('/'),

@@ -61,3 +61,3 @@ type,

this.urls[urlName]= {
this.urls['GET' + urlName]= {
file,

@@ -88,3 +88,3 @@ array: fileName.split('/'),

this.urls[route.path] = {
this.urls[route.type + route.path] = {
array: route.path.split('/'),

@@ -178,4 +178,4 @@ type: route.type,

for (const elementName in urls) {
if (elementName in urls && elementName === reqUrl.pathname && urls[elementName].type === req.method) {
executeUrl = reqUrl.pathname
if (elementName in urls && elementName.replace(req.method, '') === reqUrl.pathname && urls[elementName].type === req.method) {
executeUrl = req.method + reqUrl.pathname
isStatic = false

@@ -185,4 +185,4 @@ exists = true

break
}; if (elementName in urls && elementName === reqUrl.pathname && urls[elementName].type === 'STATIC') {
executeUrl = reqUrl.pathname
}; if (elementName in urls && elementName.replace(req.method, '') === reqUrl.pathname && urls[elementName].type === 'STATIC') {
executeUrl = req.method + reqUrl.pathname
isStatic = true

@@ -210,3 +210,3 @@ exists = true

params.set(urlParam.replace(':', ''), decodeURIComponent(reqParam))
executeUrl = element.array.join('/')
executeUrl = req.method + element.array.join('/')
exists = true

@@ -213,0 +213,0 @@

{
"name": "rjweb-server",
"version": "0.6.6",
"version": "0.6.7",
"description": "Easy and Lightweight Way to create a Web Server in Node.js",

@@ -5,0 +5,0 @@ "main": "index.js",

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