Socket
Socket
Sign inDemoInstall

rjweb-server

Package Overview
Dependencies
0
Maintainers
1
Versions
369
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.3.6 to 0.3.7

2

package.json
{
"name": "rjweb-server",
"version": "0.3.6",
"version": "0.3.7",
"description": "Easy Way to create a Web Server in Node.js",

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

@@ -27,4 +27,12 @@ const { getAllFiles } = require('./getAllFiles.js')

const fileName = file.replace(folder, '')
let urlName = ''
if (fileName.replace('/', '') === 'index.html') {
urlName = (path).replace('//', '/')
} else if (fileName.replace('/', '').endsWith('.html')) {
urlName = (path + fileName).replace('//', '/').replace('.html', '')
} else {
urlName = (path + fileName).replace('//', '/')
}
this.urls[path + fileName] = {
this.urls[urlName] = {
array: fileName.split('/'),

@@ -31,0 +39,0 @@ type: 'STATIC',

SocketSocket SOC 2 Logo

Product

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

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc