nest-knexjs 0.0.8 → 0.0.9
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/.github/workflows/codeql-analysis.yml +1 -1
- package/README.md +1 -1
- package/dist/common/index.js +5 -1
- package/dist/common/knex.utils.d.ts +1 -1
- package/dist/common/knex.utils.js +3 -0
- package/dist/exceptions/index.js +5 -1
- package/dist/index.js +5 -1
- package/dist/interfaces/index.js +5 -1
- package/package.json +24 -24
package/README.md
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
<p align="center">
|
|
2
|
-
<a href="http://nestjs.com/" target="blank"><img src="https://nestjs.com/img/
|
|
2
|
+
<a href="http://nestjs.com/" target="blank"><img src="https://nestjs.com/img/logo-small.svg" width="200" alt="Nest Logo" /></a>
|
|
3
3
|
</p>
|
|
4
4
|
|
|
5
5
|
[circleci-image]: https://img.shields.io/circleci/build/github/nestjs/nest/master?token=abc123def456
|
package/dist/common/index.js
CHANGED
|
@@ -1,7 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
3
|
if (k2 === undefined) k2 = k;
|
|
4
|
-
Object.
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
5
9
|
}) : (function(o, m, k, k2) {
|
|
6
10
|
if (k2 === undefined) k2 = k;
|
|
7
11
|
o[k2] = m[k];
|
|
@@ -7,7 +7,7 @@ import { Observable } from 'rxjs';
|
|
|
7
7
|
* @returns {string} The Entity injection token
|
|
8
8
|
*/
|
|
9
9
|
export declare function getModelToken(model: Function, connection?: KnexModuleOptions | string): string;
|
|
10
|
-
export declare function getConnectionToken(connection?: KnexModuleOptions |
|
|
10
|
+
export declare function getConnectionToken(connection?: KnexModuleOptions | string): string | Function;
|
|
11
11
|
/**
|
|
12
12
|
* This function returns a Connection prefix based on the connection name
|
|
13
13
|
* @param {KnexModuleOptions | string} [connection='default'] This optional parameter is either
|
|
@@ -22,6 +22,9 @@ function getModelToken(model, connection = knex_constants_1.DEFAULT_CONNECTION_N
|
|
|
22
22
|
}
|
|
23
23
|
exports.getModelToken = getModelToken;
|
|
24
24
|
function getConnectionToken(connection = knex_constants_1.DEFAULT_CONNECTION_NAME) {
|
|
25
|
+
if (typeof connection === 'string') {
|
|
26
|
+
return connection;
|
|
27
|
+
}
|
|
25
28
|
return `${connection.name || knex_constants_1.DEFAULT_CONNECTION_NAME}`;
|
|
26
29
|
}
|
|
27
30
|
exports.getConnectionToken = getConnectionToken;
|
package/dist/exceptions/index.js
CHANGED
|
@@ -1,7 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
3
|
if (k2 === undefined) k2 = k;
|
|
4
|
-
Object.
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
5
9
|
}) : (function(o, m, k, k2) {
|
|
6
10
|
if (k2 === undefined) k2 = k;
|
|
7
11
|
o[k2] = m[k];
|
package/dist/index.js
CHANGED
|
@@ -1,7 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
3
|
if (k2 === undefined) k2 = k;
|
|
4
|
-
Object.
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
5
9
|
}) : (function(o, m, k, k2) {
|
|
6
10
|
if (k2 === undefined) k2 = k;
|
|
7
11
|
o[k2] = m[k];
|
package/dist/interfaces/index.js
CHANGED
|
@@ -1,7 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
3
|
if (k2 === undefined) k2 = k;
|
|
4
|
-
Object.
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
5
9
|
}) : (function(o, m, k, k2) {
|
|
6
10
|
if (k2 === undefined) k2 = k;
|
|
7
11
|
o[k2] = m[k];
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "nest-knexjs",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.9",
|
|
4
4
|
"description": "Knexjs module for Nest framework (node.js) 😻",
|
|
5
5
|
"author": "Tony133",
|
|
6
6
|
"license": "MIT",
|
|
@@ -18,34 +18,34 @@
|
|
|
18
18
|
"release": "release-it"
|
|
19
19
|
},
|
|
20
20
|
"devDependencies": {
|
|
21
|
-
"@commitlint/cli": "16.
|
|
22
|
-
"@commitlint/config-angular": "16.
|
|
23
|
-
"@nestjs/common": "8.
|
|
24
|
-
"@nestjs/core": "8.
|
|
25
|
-
"@nestjs/platform-express": "8.
|
|
26
|
-
"@nestjs/testing": "8.
|
|
21
|
+
"@commitlint/cli": "16.2.3",
|
|
22
|
+
"@commitlint/config-angular": "16.2.3",
|
|
23
|
+
"@nestjs/common": "8.4.4",
|
|
24
|
+
"@nestjs/core": "8.4.4",
|
|
25
|
+
"@nestjs/platform-express": "8.4.4",
|
|
26
|
+
"@nestjs/testing": "8.4.4",
|
|
27
27
|
"@types/express": "4.17.13",
|
|
28
|
-
"@types/node": "16.11.
|
|
29
|
-
"@types/jest": "27.4.
|
|
30
|
-
"@types/supertest": "2.0.
|
|
31
|
-
"@typescript-eslint/eslint-plugin": "5.
|
|
32
|
-
"@typescript-eslint/parser": "5.
|
|
33
|
-
"eslint": "8.
|
|
34
|
-
"eslint-config-prettier": "8.
|
|
35
|
-
"eslint-plugin-import": "2.
|
|
36
|
-
"knex": "1.0.
|
|
28
|
+
"@types/node": "16.11.27",
|
|
29
|
+
"@types/jest": "27.4.1",
|
|
30
|
+
"@types/supertest": "2.0.12",
|
|
31
|
+
"@typescript-eslint/eslint-plugin": "5.19.0",
|
|
32
|
+
"@typescript-eslint/parser": "5.19.0",
|
|
33
|
+
"eslint": "8.13.0",
|
|
34
|
+
"eslint-config-prettier": "8.5.0",
|
|
35
|
+
"eslint-plugin-import": "2.26.0",
|
|
36
|
+
"knex": "1.0.7",
|
|
37
37
|
"mysql": "2.18.1",
|
|
38
38
|
"husky": "7.0.4",
|
|
39
|
-
"prettier": "2.
|
|
40
|
-
"jest": "27.
|
|
39
|
+
"prettier": "2.6.2",
|
|
40
|
+
"jest": "27.5.1",
|
|
41
41
|
"reflect-metadata": "0.1.13",
|
|
42
|
-
"release-it": "14.
|
|
42
|
+
"release-it": "14.14.2",
|
|
43
43
|
"supertest": "6.2.2",
|
|
44
|
-
"ts-node": "10.
|
|
45
|
-
"rxjs": "7.5.
|
|
46
|
-
"ts-jest": "27.1.
|
|
47
|
-
"tsconfig-paths": "3.
|
|
48
|
-
"typescript": "4.
|
|
44
|
+
"ts-node": "10.7.0",
|
|
45
|
+
"rxjs": "7.5.5",
|
|
46
|
+
"ts-jest": "27.1.4",
|
|
47
|
+
"tsconfig-paths": "3.14.1",
|
|
48
|
+
"typescript": "4.6.3"
|
|
49
49
|
},
|
|
50
50
|
"peerDependencies": {
|
|
51
51
|
"@nestjs/common": "^7.0.0 || ^8.0.0",
|