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

source-map

Package Overview
Dependencies
Maintainers
3
Versions
68
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

source-map - npm Package Compare versions

Comparing version 0.1.37 to 0.1.38

.tern-port

5

CHANGELOG.md
# Change Log
## 0.1.38
* Fix a bug where finding relative paths from an empty path were creating
absolute paths. See issue #129.
## 0.1.37

@@ -4,0 +9,0 @@

4

lib/source-map/util.js

@@ -195,2 +195,6 @@ /* -*- Mode: js; js-indent-level: 2; -*- */

function relative(aRoot, aPath) {
if (aRoot === "") {
aRoot = ".";
}
aRoot = aRoot.replace(/\/$/, '');

@@ -197,0 +201,0 @@

2

package.json
{
"name": "source-map",
"description": "Generates and consumes source maps",
"version": "0.1.37",
"version": "0.1.38",
"homepage": "https://github.com/mozilla/source-map",

@@ -6,0 +6,0 @@ "author": "Nick Fitzgerald <nfitzgerald@mozilla.com>",

@@ -206,4 +206,12 @@ /* -*- Mode: js; js-indent-level: 2; -*- */

assert.equal(libUtil.relative('/the/root', '/the/rootone.js'), '/the/rootone.js');
assert.equal(libUtil.relative('', '/the/root/one.js'), '/the/root/one.js');
assert.equal(libUtil.relative('.', '/the/root/one.js'), '/the/root/one.js');
assert.equal(libUtil.relative('', 'the/root/one.js'), 'the/root/one.js');
assert.equal(libUtil.relative('.', 'the/root/one.js'), 'the/root/one.js');
assert.equal(libUtil.relative('/', '/the/root/one.js'), 'the/root/one.js');
assert.equal(libUtil.relative('/', 'the/root/one.js'), 'the/root/one.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