@gravito/stasis 2.0.0 → 3.0.1
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.
- package/dist/index.cjs +5 -6
- package/dist/index.d.cts +533 -19
- package/dist/index.d.ts +533 -19
- package/dist/index.js +5 -6
- package/package.json +3 -1
package/dist/index.cjs
CHANGED
|
@@ -659,9 +659,6 @@ function sleep(ms) {
|
|
|
659
659
|
}
|
|
660
660
|
|
|
661
661
|
// src/stores/FileStore.ts
|
|
662
|
-
function hashKey(key) {
|
|
663
|
-
return (0, import_node_crypto.createHash)("sha1").update(key).digest("hex");
|
|
664
|
-
}
|
|
665
662
|
var FileStore = class {
|
|
666
663
|
constructor(options) {
|
|
667
664
|
this.options = options;
|
|
@@ -797,6 +794,9 @@ var FileStore = class {
|
|
|
797
794
|
};
|
|
798
795
|
}
|
|
799
796
|
};
|
|
797
|
+
function hashKey(key) {
|
|
798
|
+
return (0, import_node_crypto.createHash)("sha256").update(key).digest("hex");
|
|
799
|
+
}
|
|
800
800
|
|
|
801
801
|
// src/stores/MemoryStore.ts
|
|
802
802
|
var import_node_crypto2 = require("crypto");
|
|
@@ -1323,10 +1323,9 @@ var OrbitStasis = class {
|
|
|
1323
1323
|
this.manager = manager;
|
|
1324
1324
|
core.adapter.use("*", async (c, next) => {
|
|
1325
1325
|
c.set(exposeAs, manager);
|
|
1326
|
-
await next();
|
|
1327
|
-
return void 0;
|
|
1326
|
+
return await next();
|
|
1328
1327
|
});
|
|
1329
|
-
core.
|
|
1328
|
+
core.container.instance(exposeAs, manager);
|
|
1330
1329
|
core.hooks.doAction("cache:init", manager);
|
|
1331
1330
|
}
|
|
1332
1331
|
getCache() {
|