Comparing version 87.0.0 to 89.0.0
@@ -1,2 +0,2 @@ | ||
import { createHash } from "crypto"; | ||
import sjcl from "sjcl"; | ||
import stableHash from "stable-hash"; | ||
@@ -112,4 +112,5 @@ import { pipe } from "./composition.js"; | ||
export const retry = (waitMs, times, f) => conditionalRetry(() => true)(waitMs, times, f); | ||
export const hash = (x, maxLength) => createHash("MD5").update( | ||
const sha256 = (x) => sjcl.codec.hex.fromBits(sjcl.hash.sha256.hash(x)); | ||
export const hash = (x, maxLength) => | ||
// @ts-ignore-error error in deno but not in node | ||
stableHash(x)).digest("hex").substring(0, maxLength); | ||
sha256(stableHash(x)).substring(0, maxLength); |
{ | ||
"name": "gamla", | ||
"version": "87.0.0", | ||
"version": "89.0.0", | ||
"description": "Functional programming with async and type safety", | ||
@@ -25,3 +25,5 @@ "repository": { | ||
"dependencies": { | ||
"stable-hash": "*" | ||
"sjcl": "*", | ||
"stable-hash": "*", | ||
"@types/sjcl": "1.0.34" | ||
}, | ||
@@ -28,0 +30,0 @@ "devDependencies": { |
@@ -7,3 +7,3 @@ "use strict"; | ||
exports.hash = exports.retry = exports.conditionalRetry = exports.timeout = exports.timerCatcher = exports.batch = void 0; | ||
const crypto_1 = require("crypto"); | ||
const sjcl_1 = __importDefault(require("sjcl")); | ||
const stable_hash_1 = __importDefault(require("stable-hash")); | ||
@@ -123,5 +123,6 @@ const composition_js_1 = require("./composition.js"); | ||
exports.retry = retry; | ||
const hash = (x, maxLength) => (0, crypto_1.createHash)("MD5").update( | ||
const sha256 = (x) => sjcl_1.default.codec.hex.fromBits(sjcl_1.default.hash.sha256.hash(x)); | ||
const hash = (x, maxLength) => | ||
// @ts-ignore-error error in deno but not in node | ||
(0, stable_hash_1.default)(x)).digest("hex").substring(0, maxLength); | ||
sha256((0, stable_hash_1.default)(x)).substring(0, maxLength); | ||
exports.hash = hash; |
Wildcard dependency
QualityPackage has a dependency with a floating version range. This can cause issues if the dependency publishes a new major version.
Found 1 instance in 1 package
232742
2476
3
3
+ Added@types/sjcl@1.0.34
+ Addedsjcl@*
+ Added@types/sjcl@1.0.34(transitive)
+ Addedsjcl@1.0.8(transitive)