@midwayjs/sequelize 3.16.5 → 3.16.8
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/configuration.js
CHANGED
|
@@ -28,11 +28,11 @@ let SequelizeDataSourceManager = class SequelizeDataSourceManager extends core_1
|
|
|
28
28
|
// 兼容老写法,但是这里可能有问题,会添加到所有的数据源之中
|
|
29
29
|
const listEntities = (0, core_1.listModule)('sequelize:core');
|
|
30
30
|
client.addModels(listEntities);
|
|
31
|
-
await
|
|
32
|
-
if (config.sync) {
|
|
31
|
+
const isConnected = await this.checkConnected(client);
|
|
32
|
+
if (isConnected && config.sync) {
|
|
33
33
|
await client.sync(config.syncOptions);
|
|
34
34
|
}
|
|
35
|
-
this.coreLogger.info('[midway:sequelize]
|
|
35
|
+
this.coreLogger.info('[midway:sequelize] client created: %s', dataSourceName);
|
|
36
36
|
return client;
|
|
37
37
|
}
|
|
38
38
|
async checkConnected(dataSource) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@midwayjs/sequelize",
|
|
3
|
-
"version": "3.16.
|
|
3
|
+
"version": "3.16.8",
|
|
4
4
|
"main": "dist/index.js",
|
|
5
5
|
"typings": "index.d.ts",
|
|
6
6
|
"files": [
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
],
|
|
11
11
|
"devDependencies": {
|
|
12
12
|
"@midwayjs/core": "^3.16.2",
|
|
13
|
-
"@midwayjs/koa": "^3.16.
|
|
13
|
+
"@midwayjs/koa": "^3.16.8",
|
|
14
14
|
"@midwayjs/mock": "^3.16.5",
|
|
15
15
|
"sequelize": "6.37.3",
|
|
16
16
|
"sequelize-typescript": "2.1.6",
|
|
@@ -38,5 +38,5 @@
|
|
|
38
38
|
"type": "git",
|
|
39
39
|
"url": "https://github.com/midwayjs/midway.git"
|
|
40
40
|
},
|
|
41
|
-
"gitHead": "
|
|
41
|
+
"gitHead": "2251d0ddf91a9cad611f3aaab2e86588cc7e7756"
|
|
42
42
|
}
|