@welshman/util 0.0.46 → 0.0.47

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.
@@ -3,6 +3,6 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.toNostrURI = exports.fromNostrURI = void 0;
4
4
  const fromNostrURI = (s) => s.replace(/^nostr:\/?\/?/, "");
5
5
  exports.fromNostrURI = fromNostrURI;
6
- const toNostrURI = (s) => `nostr:${s}`;
6
+ const toNostrURI = (s) => s.startsWith('nostr:') ? s : `nostr:${s}`;
7
7
  exports.toNostrURI = toNostrURI;
8
8
  //# sourceMappingURL=Links.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"Links.cjs","sourceRoot":"","sources":["../../src/Links.ts"],"names":[],"mappings":";;;AAAO,MAAM,YAAY,GAAG,CAAC,CAAS,EAAE,EAAE,CAAC,CAAC,CAAC,OAAO,CAAC,eAAe,EAAE,EAAE,CAAC,CAAA;AAA5D,QAAA,YAAY,gBAAgD;AAElE,MAAM,UAAU,GAAG,CAAC,CAAS,EAAE,EAAE,CAAC,SAAS,CAAC,EAAE,CAAA;AAAxC,QAAA,UAAU,cAA8B"}
1
+ {"version":3,"file":"Links.cjs","sourceRoot":"","sources":["../../src/Links.ts"],"names":[],"mappings":";;;AAAO,MAAM,YAAY,GAAG,CAAC,CAAS,EAAE,EAAE,CAAC,CAAC,CAAC,OAAO,CAAC,eAAe,EAAE,EAAE,CAAC,CAAA;AAA5D,QAAA,YAAY,gBAAgD;AAElE,MAAM,UAAU,GAAG,CAAC,CAAS,EAAE,EAAE,CAAC,CAAC,CAAC,UAAU,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,EAAE,CAAA;AAArE,QAAA,UAAU,cAA2D"}
@@ -1,3 +1,3 @@
1
1
  export const fromNostrURI = (s) => s.replace(/^nostr:\/?\/?/, "");
2
- export const toNostrURI = (s) => `nostr:${s}`;
2
+ export const toNostrURI = (s) => s.startsWith('nostr:') ? s : `nostr:${s}`;
3
3
  //# sourceMappingURL=Links.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"Links.mjs","sourceRoot":"","sources":["../../src/Links.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,YAAY,GAAG,CAAC,CAAS,EAAE,EAAE,CAAC,CAAC,CAAC,OAAO,CAAC,eAAe,EAAE,EAAE,CAAC,CAAA;AAEzE,MAAM,CAAC,MAAM,UAAU,GAAG,CAAC,CAAS,EAAE,EAAE,CAAC,SAAS,CAAC,EAAE,CAAA"}
1
+ {"version":3,"file":"Links.mjs","sourceRoot":"","sources":["../../src/Links.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,YAAY,GAAG,CAAC,CAAS,EAAE,EAAE,CAAC,CAAC,CAAC,OAAO,CAAC,eAAe,EAAE,EAAE,CAAC,CAAA;AAEzE,MAAM,CAAC,MAAM,UAAU,GAAG,CAAC,CAAS,EAAE,EAAE,CAAC,CAAC,CAAC,UAAU,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,EAAE,CAAA"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@welshman/util",
3
- "version": "0.0.46",
3
+ "version": "0.0.47",
4
4
  "author": "hodlbod",
5
5
  "license": "MIT",
6
6
  "description": "A collection of nostr-related utilities.",
@@ -31,7 +31,7 @@
31
31
  "typescript": "~5.1.6"
32
32
  },
33
33
  "dependencies": {
34
- "@welshman/lib": "~0.0.27",
34
+ "@welshman/lib": "~0.0.28",
35
35
  "nostr-tools": "^2.7.2"
36
36
  }
37
37
  }