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

hlx-url-rewriter

Package Overview
Dependencies
Maintainers
1
Versions
25
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

hlx-url-rewriter - npm Package Compare versions

Comparing version 0.0.9 to 0.0.10

16

default.js

@@ -57,4 +57,18 @@ const path = require('path');

print(`\t<<< "${uri}", "${base}"`);
let result;
const obj = createUrl(uri, base);
const result = `${path.join(`/${obj.hostname}`, obj.pathname)}${obj.search}${obj.hash}`;
const scheme = 'file:';
if (obj.protocol === scheme) {
const filePath = obj.pathname;
if (base && uri.startsWith(scheme)) {
const obj = createUrl(base);
base = obj.pathname;
console.log(`###path.relative(path.dirname(${base}), ${filePath})`);
result = `/${path.relative(path.dirname(base), filePath)}`;
} else {
result = filePath;
}
} else {
result = `${path.join(`/${obj.hostname}`, obj.pathname)}${obj.search}${obj.hash}`;
}
print(`\t>>> "${result}"`);

@@ -61,0 +75,0 @@ return result;

2

package.json
{
"name": "hlx-url-rewriter",
"version": "0.0.9",
"version": "0.0.10",
"description": "A transform stream to modify URLs contained in HLS playlists",

@@ -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