@avleon/core 0.0.37 → 0.0.38

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/dist/icore.js +4 -1
  2. package/package.json +1 -1
package/dist/icore.js CHANGED
@@ -61,6 +61,7 @@ const utils_1 = require("./utils");
61
61
  const socket_io_1 = require("socket.io");
62
62
  const event_subscriber_1 = require("./event-subscriber");
63
63
  const stream_1 = __importDefault(require("stream"));
64
+ const kenx_provider_1 = require("./kenx-provider");
64
65
  const isTsNode = process.env.TS_NODE_DEV ||
65
66
  process.env.TS_NODE_PROJECT ||
66
67
  process[Symbol.for("ts-node.register.instance")];
@@ -239,7 +240,9 @@ class AvleonApplication {
239
240
  }
240
241
  if (!dataSourceOptions)
241
242
  throw new system_exception_1.SystemUseError("Invlaid datasource options.");
242
- (0, container_1.registerKnex)(dataSourceOptions);
243
+ //registerKnex(dataSourceOptions);
244
+ const db = typedi_1.default.get(kenx_provider_1.DB);
245
+ db.init(dataSourceOptions);
243
246
  }
244
247
  _useCache(options) { }
245
248
  useMiddlewares(mclasses) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@avleon/core",
3
- "version": "0.0.37",
3
+ "version": "0.0.38",
4
4
  "main": "./dist/index.js",
5
5
  "types": "./dist/index.d.ts",
6
6
  "keywords": [