@medusajs/cache-inmemory 2.0.0-snapshot-20230313175443 → 2.0.0-snapshot-20230320172940

Sign up to get free protection for your applications and to get access to all the features.
package/dist/index.js CHANGED
@@ -4,11 +4,9 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
6
  var inmemory_cache_1 = __importDefault(require("./services/inmemory-cache"));
7
- var loaders = [];
8
7
  var service = inmemory_cache_1.default;
9
8
  var moduleDefinition = {
10
9
  service: service,
11
- loaders: loaders,
12
10
  };
13
11
  exports.default = moduleDefinition;
14
12
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;AAEA,6EAA4D;AAE5D,IAAM,OAAO,GAAG,EAAE,CAAA;AAClB,IAAM,OAAO,GAAG,wBAAoB,CAAA;AAEpC,IAAM,gBAAgB,GAAkB;IACtC,OAAO,SAAA;IACP,OAAO,SAAA;CACR,CAAA;AAED,kBAAe,gBAAgB,CAAA"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;AAEA,6EAA4D;AAE5D,IAAM,OAAO,GAAG,wBAAoB,CAAA;AAEpC,IAAM,gBAAgB,GAAkB;IACtC,OAAO,SAAA;CACR,CAAA;AAED,kBAAe,gBAAgB,CAAA"}
@@ -88,6 +88,7 @@ var InMemoryCacheService = /** @class */ (function () {
88
88
  ref = setTimeout(function () {
89
89
  _this.invalidate(key);
90
90
  }, ttl * 1000);
91
+ ref.unref();
91
92
  this.timoutRefs.set(key, ref);
92
93
  this.store.set(key, record);
93
94
  return [2 /*return*/];
@@ -1 +1 @@
1
- {"version":3,"file":"inmemory-cache.js","sourceRoot":"","sources":["../../src/services/inmemory-cache.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAIA,IAAM,WAAW,GAAG,E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AAG,CAAC,CAAA;gBACxB,CAAC,CAAC,CAAA;;;;KACH;IAED;;OAEG;IACG,oCAAK,GAAX;;;gBACE,IAAI,CAAC,UAAU,CAAC,OAAO,CAAC,UAAC,GAAG,IAAK,OAAA,YAAY,CAAC,GAAG,CAAC,EAAjB,CAAiB,CAAC,CAAA;gBACnD,IAAI,CAAC,UAAU,CAAC,KAAK,EAAE,CAAA;gBAEvB,IAAI,CAAC,KAAK,CAAC,KAAK,EAAE,CAAA;;;;KACnB;IACH,2BAAC;AAAD,CAAC,AAzFD,IAyFC;AAED,kBAAe,oBAAoB,CAAA"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@medusajs/cache-inmemory",
3
- "version": "2.0.0-snapshot-20230313175443",
3
+ "version": "2.0.0-snapshot-20230320172940",
4
4
  "description": "In-memory Cache Module for Medusa",
5
5
  "main": "dist/index.js",
6
6
  "repository": {
@@ -17,7 +17,7 @@
17
17
  "author": "Medusa",
18
18
  "license": "MIT",
19
19
  "devDependencies": {
20
- "@medusajs/medusa": "2.0.0-snapshot-20230313175443",
20
+ "@medusajs/medusa": "2.0.0-snapshot-20230320172940",
21
21
  "cross-env": "^5.2.1",
22
22
  "jest": "^25.5.4",
23
23
  "ts-jest": "^25.5.1",
@@ -31,6 +31,6 @@
31
31
  "test:unit": "jest --passWithNoTests"
32
32
  },
33
33
  "peerDependencies": {
34
- "@medusajs/medusa": "2.0.0-snapshot-20230313175443"
34
+ "@medusajs/medusa": "2.0.0-snapshot-20230320172940"
35
35
  }
36
36
  }