Socket
Socket
Sign inDemoInstall

@kano/desktop-shell

Package Overview
Dependencies
Maintainers
8
Versions
10
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@kano/desktop-shell - npm Package Compare versions

Comparing version 1.0.5 to 1.0.6

7

lib/spa-stream-protocol-handler.js

@@ -15,5 +15,10 @@ const url = require('url');

const postProcess = opts.postProcess || (s => s);
const authorities = opts.authorities || {};
return (req, callback) => {
// Parse the url to extract the pathname
const u = url.parse(req.url);
// Authority called host in URLs
const { host } = u;
// Use the root defined in the authorities routing or default ot the default root
const authorityRoot = authorities[host] || root;
let extension = getExtension(u.pathname);

@@ -25,3 +30,3 @@ // If the path contains an extension, it is a request for a file

extension = getExtension(filename);
const file = path.normalize(`${root}/${filename}`);
const file = path.normalize(`${authorityRoot}/${filename}`);
const mimeType = mime.lookup(extension);

@@ -28,0 +33,0 @@ const stream = fs.createReadStream(file);

2

package.json
{
"name": "@kano/desktop-shell",
"version": "1.0.5",
"version": "1.0.6",
"description": "",

@@ -5,0 +5,0 @@ "main": "lib/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