orange-orm 5.3.1 → 5.3.2
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.browser.mjs +21 -11
- package/dist/index.mjs +21 -11
- package/docs/changelog.md +3 -0
- package/package.json +4 -5
- package/src/client/createPatch.js +2 -2
- package/src/client/toKeyPositionMap.js +3 -3
- package/src/newId.js +1 -2
- package/src/newMemoryId.js +5 -0
- package/deno.lock +0 -75
- package/other.db +0 -0
package/dist/index.browser.mjs
CHANGED
|
@@ -2,7 +2,6 @@ void !function() {
|
|
|
2
2
|
typeof self === 'undefined' && typeof global === 'object'
|
|
3
3
|
? global.self = global : null;
|
|
4
4
|
}();import * as fastJsonPatch from 'fast-json-patch';
|
|
5
|
-
import * as uuid from 'uuid';
|
|
6
5
|
import * as axios from 'axios';
|
|
7
6
|
import * as _default from 'rfdc/default';
|
|
8
7
|
import * as ajv from 'ajv';
|
|
@@ -973,7 +972,7 @@ function requireHostHono () {
|
|
|
973
972
|
return hostHono_1;
|
|
974
973
|
}
|
|
975
974
|
|
|
976
|
-
var require$$0$
|
|
975
|
+
var require$$0$2 = /*@__PURE__*/getDefaultExportFromNamespaceIfPresent(fastJsonPatch);
|
|
977
976
|
|
|
978
977
|
var dateToISOString_1;
|
|
979
978
|
var hasRequiredDateToISOString;
|
|
@@ -1035,7 +1034,19 @@ function requireStringify () {
|
|
|
1035
1034
|
return stringify_1;
|
|
1036
1035
|
}
|
|
1037
1036
|
|
|
1038
|
-
var
|
|
1037
|
+
var newMemoryId;
|
|
1038
|
+
var hasRequiredNewMemoryId;
|
|
1039
|
+
|
|
1040
|
+
function requireNewMemoryId () {
|
|
1041
|
+
if (hasRequiredNewMemoryId) return newMemoryId;
|
|
1042
|
+
hasRequiredNewMemoryId = 1;
|
|
1043
|
+
let nextId = 1;
|
|
1044
|
+
|
|
1045
|
+
newMemoryId = function newMemoryId() {
|
|
1046
|
+
return `tmp${nextId++}`;
|
|
1047
|
+
};
|
|
1048
|
+
return newMemoryId;
|
|
1049
|
+
}
|
|
1039
1050
|
|
|
1040
1051
|
var createPatch;
|
|
1041
1052
|
var hasRequiredCreatePatch;
|
|
@@ -1043,10 +1054,10 @@ var hasRequiredCreatePatch;
|
|
|
1043
1054
|
function requireCreatePatch () {
|
|
1044
1055
|
if (hasRequiredCreatePatch) return createPatch;
|
|
1045
1056
|
hasRequiredCreatePatch = 1;
|
|
1046
|
-
const jsonpatch = require$$0$
|
|
1057
|
+
const jsonpatch = require$$0$2;
|
|
1047
1058
|
let dateToIsoString = requireDateToISOString();
|
|
1048
1059
|
let stringify = requireStringify();
|
|
1049
|
-
let
|
|
1060
|
+
let newMemoryId = requireNewMemoryId();
|
|
1050
1061
|
|
|
1051
1062
|
createPatch = function createPatch(original, dto, options) {
|
|
1052
1063
|
let subject = toCompareObject({ d: original }, options, true);
|
|
@@ -1155,7 +1166,7 @@ function requireCreatePatch () {
|
|
|
1155
1166
|
|
|
1156
1167
|
function negotiateTempKey(value) {
|
|
1157
1168
|
if (value === undefined)
|
|
1158
|
-
return `~${
|
|
1169
|
+
return `~${newMemoryId()}`;
|
|
1159
1170
|
else
|
|
1160
1171
|
return value;
|
|
1161
1172
|
}
|
|
@@ -2972,7 +2983,7 @@ function requireToKeyPositionMap () {
|
|
|
2972
2983
|
if (hasRequiredToKeyPositionMap) return toKeyPositionMap_1;
|
|
2973
2984
|
hasRequiredToKeyPositionMap = 1;
|
|
2974
2985
|
const stringify = requireStringify();
|
|
2975
|
-
const
|
|
2986
|
+
const newMemoryId = requireNewMemoryId();
|
|
2976
2987
|
|
|
2977
2988
|
function toKeyPositionMap(rows, options) {
|
|
2978
2989
|
return rows.reduce((map, element, i) => {
|
|
@@ -2995,7 +3006,7 @@ function requireToKeyPositionMap () {
|
|
|
2995
3006
|
|
|
2996
3007
|
function negotiateTempKey(value) {
|
|
2997
3008
|
if (value === undefined)
|
|
2998
|
-
return `~${
|
|
3009
|
+
return `~${newMemoryId()}`;
|
|
2999
3010
|
else
|
|
3000
3011
|
return value;
|
|
3001
3012
|
}
|
|
@@ -11073,8 +11084,7 @@ var hasRequiredNewId;
|
|
|
11073
11084
|
function requireNewId () {
|
|
11074
11085
|
if (hasRequiredNewId) return newId;
|
|
11075
11086
|
hasRequiredNewId = 1;
|
|
11076
|
-
|
|
11077
|
-
newId = uuid;
|
|
11087
|
+
newId = requireNewMemoryId();
|
|
11078
11088
|
return newId;
|
|
11079
11089
|
}
|
|
11080
11090
|
|
|
@@ -12460,7 +12470,7 @@ var hasRequiredApplyPatch;
|
|
|
12460
12470
|
function requireApplyPatch () {
|
|
12461
12471
|
if (hasRequiredApplyPatch) return applyPatch_1;
|
|
12462
12472
|
hasRequiredApplyPatch = 1;
|
|
12463
|
-
const fastjson = require$$0$
|
|
12473
|
+
const fastjson = require$$0$2;
|
|
12464
12474
|
let fromCompareObject = requireFromCompareObject();
|
|
12465
12475
|
let toCompareObject = requireToCompareObject();
|
|
12466
12476
|
let getSessionSingleton = requireGetSessionSingleton();
|
package/dist/index.mjs
CHANGED
|
@@ -2,7 +2,6 @@ void !function() {
|
|
|
2
2
|
typeof self === 'undefined' && typeof global === 'object'
|
|
3
3
|
? global.self = global : null;
|
|
4
4
|
}();import * as fastJsonPatch from 'fast-json-patch';
|
|
5
|
-
import * as uuid from 'uuid';
|
|
6
5
|
import * as axios from 'axios';
|
|
7
6
|
import * as _default from 'rfdc/default';
|
|
8
7
|
import * as ajv from 'ajv';
|
|
@@ -974,7 +973,7 @@ function requireHostHono () {
|
|
|
974
973
|
return hostHono_1;
|
|
975
974
|
}
|
|
976
975
|
|
|
977
|
-
var require$$0$
|
|
976
|
+
var require$$0$3 = /*@__PURE__*/getDefaultExportFromNamespaceIfPresent(fastJsonPatch);
|
|
978
977
|
|
|
979
978
|
var dateToISOString_1;
|
|
980
979
|
var hasRequiredDateToISOString;
|
|
@@ -1036,7 +1035,19 @@ function requireStringify () {
|
|
|
1036
1035
|
return stringify_1;
|
|
1037
1036
|
}
|
|
1038
1037
|
|
|
1039
|
-
var
|
|
1038
|
+
var newMemoryId;
|
|
1039
|
+
var hasRequiredNewMemoryId;
|
|
1040
|
+
|
|
1041
|
+
function requireNewMemoryId () {
|
|
1042
|
+
if (hasRequiredNewMemoryId) return newMemoryId;
|
|
1043
|
+
hasRequiredNewMemoryId = 1;
|
|
1044
|
+
let nextId = 1;
|
|
1045
|
+
|
|
1046
|
+
newMemoryId = function newMemoryId() {
|
|
1047
|
+
return `tmp${nextId++}`;
|
|
1048
|
+
};
|
|
1049
|
+
return newMemoryId;
|
|
1050
|
+
}
|
|
1040
1051
|
|
|
1041
1052
|
var createPatch;
|
|
1042
1053
|
var hasRequiredCreatePatch;
|
|
@@ -1044,10 +1055,10 @@ var hasRequiredCreatePatch;
|
|
|
1044
1055
|
function requireCreatePatch () {
|
|
1045
1056
|
if (hasRequiredCreatePatch) return createPatch;
|
|
1046
1057
|
hasRequiredCreatePatch = 1;
|
|
1047
|
-
const jsonpatch = require$$0$
|
|
1058
|
+
const jsonpatch = require$$0$3;
|
|
1048
1059
|
let dateToIsoString = requireDateToISOString();
|
|
1049
1060
|
let stringify = requireStringify();
|
|
1050
|
-
let
|
|
1061
|
+
let newMemoryId = requireNewMemoryId();
|
|
1051
1062
|
|
|
1052
1063
|
createPatch = function createPatch(original, dto, options) {
|
|
1053
1064
|
let subject = toCompareObject({ d: original }, options, true);
|
|
@@ -1156,7 +1167,7 @@ function requireCreatePatch () {
|
|
|
1156
1167
|
|
|
1157
1168
|
function negotiateTempKey(value) {
|
|
1158
1169
|
if (value === undefined)
|
|
1159
|
-
return `~${
|
|
1170
|
+
return `~${newMemoryId()}`;
|
|
1160
1171
|
else
|
|
1161
1172
|
return value;
|
|
1162
1173
|
}
|
|
@@ -2973,7 +2984,7 @@ function requireToKeyPositionMap () {
|
|
|
2973
2984
|
if (hasRequiredToKeyPositionMap) return toKeyPositionMap_1;
|
|
2974
2985
|
hasRequiredToKeyPositionMap = 1;
|
|
2975
2986
|
const stringify = requireStringify();
|
|
2976
|
-
const
|
|
2987
|
+
const newMemoryId = requireNewMemoryId();
|
|
2977
2988
|
|
|
2978
2989
|
function toKeyPositionMap(rows, options) {
|
|
2979
2990
|
return rows.reduce((map, element, i) => {
|
|
@@ -2996,7 +3007,7 @@ function requireToKeyPositionMap () {
|
|
|
2996
3007
|
|
|
2997
3008
|
function negotiateTempKey(value) {
|
|
2998
3009
|
if (value === undefined)
|
|
2999
|
-
return `~${
|
|
3010
|
+
return `~${newMemoryId()}`;
|
|
3000
3011
|
else
|
|
3001
3012
|
return value;
|
|
3002
3013
|
}
|
|
@@ -11074,8 +11085,7 @@ var hasRequiredNewId;
|
|
|
11074
11085
|
function requireNewId () {
|
|
11075
11086
|
if (hasRequiredNewId) return newId;
|
|
11076
11087
|
hasRequiredNewId = 1;
|
|
11077
|
-
|
|
11078
|
-
newId = uuid;
|
|
11088
|
+
newId = requireNewMemoryId();
|
|
11079
11089
|
return newId;
|
|
11080
11090
|
}
|
|
11081
11091
|
|
|
@@ -12461,7 +12471,7 @@ var hasRequiredApplyPatch;
|
|
|
12461
12471
|
function requireApplyPatch () {
|
|
12462
12472
|
if (hasRequiredApplyPatch) return applyPatch_1;
|
|
12463
12473
|
hasRequiredApplyPatch = 1;
|
|
12464
|
-
const fastjson = require$$0$
|
|
12474
|
+
const fastjson = require$$0$3;
|
|
12465
12475
|
let fromCompareObject = requireFromCompareObject();
|
|
12466
12476
|
let toCompareObject = requireToCompareObject();
|
|
12467
12477
|
let getSessionSingleton = requireGetSessionSingleton();
|
package/docs/changelog.md
CHANGED
|
@@ -1,4 +1,7 @@
|
|
|
1
1
|
## Changelog
|
|
2
|
+
__5.3.2__
|
|
3
|
+
Removed uuid dependency.
|
|
4
|
+
Upgraded to tedious@19.2.1 to reduce transitive audit vulnerabilities in the MSSQL driver chain.
|
|
2
5
|
__5.3.1__
|
|
3
6
|
Fixes crashes in getById/getMany when a missing relation has nested hasMany/hasOne/references in the strategy. [#177](https://github.com/alfateam/orange-orm/issues/177)
|
|
4
7
|
Added max parameter chunking for getManyDto hasMany subqueries on MSSQL, SQLite and Oracle.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "orange-orm",
|
|
3
|
-
"version": "5.3.
|
|
3
|
+
"version": "5.3.2",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public"
|
|
6
6
|
},
|
|
@@ -81,8 +81,7 @@
|
|
|
81
81
|
"ajv": "^8.17.1",
|
|
82
82
|
"axios": "^1.6.2",
|
|
83
83
|
"fast-json-patch": "^3.1.1",
|
|
84
|
-
"rfdc": "^1.2.0"
|
|
85
|
-
"uuid": "^8.3.2 || ^9.0.0 || ^10.0.0 || ^11.1.0"
|
|
84
|
+
"rfdc": "^1.2.0"
|
|
86
85
|
},
|
|
87
86
|
"peerDependencies": {
|
|
88
87
|
"@electric-sql/pglite": "^0.3.0",
|
|
@@ -92,7 +91,7 @@
|
|
|
92
91
|
"oracledb": "^6.3.0",
|
|
93
92
|
"pg": "^8.5.1",
|
|
94
93
|
"pg-query-stream": "^3.3.2",
|
|
95
|
-
"tedious": "^15.1.2 || ^16.0.0 || ^18.1.0 ||
|
|
94
|
+
"tedious": "^15.1.2 || ^16.0.0 || ^18.1.0 || ^19.0.0"
|
|
96
95
|
},
|
|
97
96
|
"peerDependenciesMeta": {
|
|
98
97
|
"pg": {
|
|
@@ -145,7 +144,7 @@
|
|
|
145
144
|
"pg": "^8.5.1",
|
|
146
145
|
"pg-query-stream": "^3.3.2",
|
|
147
146
|
"rollup": "^2.52.7",
|
|
148
|
-
"tedious": "^19.
|
|
147
|
+
"tedious": "^19.2.1",
|
|
149
148
|
"typescript": "^5.4.5",
|
|
150
149
|
"vitest": "^3.2.4"
|
|
151
150
|
},
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
const jsonpatch = require('fast-json-patch');
|
|
2
2
|
let dateToIsoString = require('../dateToISOString');
|
|
3
3
|
let stringify = require('./stringify');
|
|
4
|
-
let
|
|
4
|
+
let newMemoryId = require('../newMemoryId');
|
|
5
5
|
|
|
6
6
|
module.exports = function createPatch(original, dto, options) {
|
|
7
7
|
let subject = toCompareObject({ d: original }, options, true);
|
|
@@ -110,7 +110,7 @@ module.exports = function createPatch(original, dto, options) {
|
|
|
110
110
|
|
|
111
111
|
function negotiateTempKey(value) {
|
|
112
112
|
if (value === undefined)
|
|
113
|
-
return `~${
|
|
113
|
+
return `~${newMemoryId()}`;
|
|
114
114
|
else
|
|
115
115
|
return value;
|
|
116
116
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
const stringify = require('./stringify');
|
|
2
|
-
const
|
|
2
|
+
const newMemoryId = require('../newMemoryId');
|
|
3
3
|
|
|
4
4
|
function toKeyPositionMap(rows, options) {
|
|
5
5
|
return rows.reduce((map, element, i) => {
|
|
@@ -22,9 +22,9 @@ function toKeyPositionMap(rows, options) {
|
|
|
22
22
|
|
|
23
23
|
function negotiateTempKey(value) {
|
|
24
24
|
if (value === undefined)
|
|
25
|
-
return `~${
|
|
25
|
+
return `~${newMemoryId()}`;
|
|
26
26
|
else
|
|
27
27
|
return value;
|
|
28
28
|
}
|
|
29
29
|
|
|
30
|
-
module.exports = toKeyPositionMap;
|
|
30
|
+
module.exports = toKeyPositionMap;
|
package/src/newId.js
CHANGED
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
module.exports = uuid;
|
|
1
|
+
module.exports = require('./newMemoryId');
|
package/deno.lock
DELETED
|
@@ -1,75 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": "5",
|
|
3
|
-
"specifiers": {
|
|
4
|
-
"jsr:@std/assert@*": "1.0.19",
|
|
5
|
-
"jsr:@std/assert@^1.0.17": "1.0.19",
|
|
6
|
-
"jsr:@std/internal@^1.0.12": "1.0.12",
|
|
7
|
-
"jsr:@std/path@*": "1.1.4",
|
|
8
|
-
"jsr:@std/testing@*": "1.0.17"
|
|
9
|
-
},
|
|
10
|
-
"jsr": {
|
|
11
|
-
"@std/assert@1.0.19": {
|
|
12
|
-
"integrity": "eaada96ee120cb980bc47e040f82814d786fe8162ecc53c91d8df60b8755991e",
|
|
13
|
-
"dependencies": [
|
|
14
|
-
"jsr:@std/internal"
|
|
15
|
-
]
|
|
16
|
-
},
|
|
17
|
-
"@std/internal@1.0.12": {
|
|
18
|
-
"integrity": "972a634fd5bc34b242024402972cd5143eac68d8dffaca5eaa4dba30ce17b027"
|
|
19
|
-
},
|
|
20
|
-
"@std/path@1.1.4": {
|
|
21
|
-
"integrity": "1d2d43f39efb1b42f0b1882a25486647cb851481862dc7313390b2bb044314b5",
|
|
22
|
-
"dependencies": [
|
|
23
|
-
"jsr:@std/internal"
|
|
24
|
-
]
|
|
25
|
-
},
|
|
26
|
-
"@std/testing@1.0.17": {
|
|
27
|
-
"integrity": "87bdc2700fa98249d48a17cd72413352d3d3680dcfbdb64947fd0982d6bbf681",
|
|
28
|
-
"dependencies": [
|
|
29
|
-
"jsr:@std/assert@^1.0.17",
|
|
30
|
-
"jsr:@std/internal"
|
|
31
|
-
]
|
|
32
|
-
}
|
|
33
|
-
},
|
|
34
|
-
"workspace": {
|
|
35
|
-
"packageJson": {
|
|
36
|
-
"dependencies": [
|
|
37
|
-
"npm:@cloudflare/workers-types@^4.20241106.0",
|
|
38
|
-
"npm:@electric-sql/pglite@0.3",
|
|
39
|
-
"npm:@hono/node-server@^1.14.4",
|
|
40
|
-
"npm:@lroal/on-change@^4.0.2",
|
|
41
|
-
"npm:@rollup/plugin-commonjs@^28.0.2",
|
|
42
|
-
"npm:@rollup/plugin-json@^6.1.0",
|
|
43
|
-
"npm:@rollup/plugin-node-resolve@13",
|
|
44
|
-
"npm:@tediousjs/connection-string@~0.4.1",
|
|
45
|
-
"npm:@types/express@^4.17.13",
|
|
46
|
-
"npm:@types/oracledb@^6.0.4",
|
|
47
|
-
"npm:@types/tedious@^4.0.14",
|
|
48
|
-
"npm:@typescript-eslint/eslint-plugin@^8.56.1",
|
|
49
|
-
"npm:@typescript-eslint/parser@^8.56.1",
|
|
50
|
-
"npm:@vitest/coverage-v8@^3.2.4",
|
|
51
|
-
"npm:ajv@^8.17.1",
|
|
52
|
-
"npm:axios@^1.6.2",
|
|
53
|
-
"npm:better-sqlite3@^12.6.2",
|
|
54
|
-
"npm:cors@^2.8.5",
|
|
55
|
-
"npm:eslint-plugin-jest@^29.15.0",
|
|
56
|
-
"npm:eslint@^8.57.0",
|
|
57
|
-
"npm:express@^4.18.2",
|
|
58
|
-
"npm:fast-json-patch@^3.1.1",
|
|
59
|
-
"npm:hono@^4.8.2",
|
|
60
|
-
"npm:msnodesqlv8@^4.1.0",
|
|
61
|
-
"npm:mysql2@^3.9.4",
|
|
62
|
-
"npm:oracledb@^6.3.0",
|
|
63
|
-
"npm:owasp-dependency-check@^0.0.21",
|
|
64
|
-
"npm:pg-query-stream@^3.3.2",
|
|
65
|
-
"npm:pg@^8.5.1",
|
|
66
|
-
"npm:rfdc@^1.2.0",
|
|
67
|
-
"npm:rollup@^2.52.7",
|
|
68
|
-
"npm:tedious@19",
|
|
69
|
-
"npm:typescript@^5.4.5",
|
|
70
|
-
"npm:uuid@^8.3.2 || 9 || 10 || ^11.1.0",
|
|
71
|
-
"npm:vitest@^3.2.4"
|
|
72
|
-
]
|
|
73
|
-
}
|
|
74
|
-
}
|
|
75
|
-
}
|
package/other.db
DELETED
|
Binary file
|