smipper 4.0.0 → 5.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/index.js +4 -1
  2. package/package.json +1 -1
package/index.js CHANGED
@@ -101,6 +101,9 @@ function processFrame(functionName, url, line, column)
101
101
  let newUrl, newLine, newColumn;
102
102
  if (verbose)
103
103
  console.error("calling loadUri", url);
104
+ if (!url.includes("://") && url[0] !== "/" && fs.existsSync(url)) {
105
+ url = `file://${process.cwd()}/${url}`;
106
+ }
104
107
  return loadUri(url).then((smap) => {
105
108
  if (verbose)
106
109
  console.error("got map", url, Object.keys(smap));
@@ -122,7 +125,7 @@ function processFrame(functionName, url, line, column)
122
125
  newColumn = pos.column;
123
126
  }).catch((err) => {
124
127
  if (verbose)
125
- console.error("didn't get map", url);
128
+ console.error("didn't get map", url, err);
126
129
  // console.error(err);
127
130
  }).finally(() => {
128
131
  if (json) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "smipper",
3
- "version": "4.0.0",
3
+ "version": "5.0.0",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {